Commit 9a18ee30b6da61adeaa6c8b77081c61b09744a83

Authored by Geoffrey PREUD'HOMME
1 parent d03db7d0

Notifications : Efface le message si erreur vide

Showing 1 changed file with 6 additions and 0 deletions   Show diff stats
public/js/services/NotifyServ.js
... ... @@ -38,6 +38,9 @@ angular.module('NotifyServ', []).service('NotifyServ', [
38 38 console.warn(message);
39 39 },
40 40 error: function (context, error) {
  41 + if (!error) {
  42 + error = '';
  43 + }
41 44 this.notify({
42 45 title: context,
43 46 message: error
... ... @@ -80,6 +83,9 @@ angular.module('NotifyServ', []).service('NotifyServ', [
80 83 });
81 84 },
82 85 error: function (context, error) {
  86 + if (!error) {
  87 + error = '';
  88 + }
83 89 commands = {
84 90 title: context,
85 91 message: error,
... ...