Change naming and veriy test-scheduler function
[bottlenecks.git] / test-scheduler / ui / src / components / message / showMessage.js
@@ -1,30 +1,30 @@
-import toastr from '../../assets/js/toastr.min.js'\r
-export default function(type, title, info, detail="") {\r
-    if(typeof type == "number") {\r
-        if(200 <= type && type < 300) {\r
-            type = "success";\r
-        } else if (300 <= type && type < 500) {\r
-            type = "warning";\r
-        } else if (500 <= type) {\r
-            type = "error";\r
-        } else {\r
-            type = "info";\r
-        }\r
-    }\r
-    if(detail != "") {\r
-        detail = "* <strong>detail:</strong>  " + detail;\r
-    }\r
-    var content = "<br>* " + info + "<br><br>" + detail;\r
-    if(type == "success"){\r
-        toastr.success(content, title);\r
-    }\r
-    else if(type == "info") {\r
-        toastr.info(content, title);\r
-    }\r
-    else if(type == "error"){\r
-        toastr.error(content, title);\r
-    }\r
-    else {\r
-        toastr.warning(content, title);\r
-    }\r
-}
\ No newline at end of file
+import toastr from '../../assets/js/toastr.min.js'
+export default function(type, title, info, detail="") {
+    if(typeof type == "number") {
+        if(200 <= type && type < 300) {
+            type = "success";
+        } else if (300 <= type && type < 500) {
+            type = "warning";
+        } else if (500 <= type) {
+            type = "error";
+        } else {
+            type = "info";
+        }
+    }
+    if(detail != "") {
+        detail = "* <strong>detail:</strong>  " + detail;
+    }
+    var content = "<br>* " + info + "<br><br>" + detail;
+    if(type == "success"){
+        toastr.success(content, title);
+    }
+    else if(type == "info") {
+        toastr.info(content, title);
+    }
+    else if(type == "error"){
+        toastr.error(content, title);
+    }
+    else {
+        toastr.warning(content, title);
+    }
+}