From d05cbf6fdeacd16af7d598f7eca891100d3931b9 Mon Sep 17 00:00:00 2001 From: Michael Mayer Date: Sun, 19 Apr 2020 01:28:35 +0200 Subject: [PATCH] Frontend: Format code Signed-off-by: Michael Mayer --- frontend/src/common/config.js | 2 +- frontend/src/model/model.js | 18 +++++++++--------- frontend/src/model/photo.js | 30 +++++++++++++++--------------- 3 files changed, 25 insertions(+), 25 deletions(-) diff --git a/frontend/src/common/config.js b/frontend/src/common/config.js index f64b43969..9bbff52d1 100644 --- a/frontend/src/common/config.js +++ b/frontend/src/common/config.js @@ -119,7 +119,7 @@ class Config { } settings() { - return this.values.settings + return this.values.settings; } } diff --git a/frontend/src/model/model.js b/frontend/src/model/model.js index 710f22c0e..b201cc62b 100644 --- a/frontend/src/model/model.js +++ b/frontend/src/model/model.js @@ -36,15 +36,15 @@ class Model { let val; if (defaults.hasOwnProperty(key)) { switch (typeof defaults[key]) { - case "bigint": - case "number": - val = parseFloat(this[key]); - break; - case "boolean": - val = !!this[key]; - break; - default: - val = this[key]; + case "bigint": + case "number": + val = parseFloat(this[key]); + break; + case "boolean": + val = !!this[key]; + break; + default: + val = this[key]; } } else { val = this[key]; diff --git a/frontend/src/model/photo.js b/frontend/src/model/photo.js index 7e27c9de4..007eb9ce2 100644 --- a/frontend/src/model/photo.js +++ b/frontend/src/model/photo.js @@ -2,14 +2,14 @@ import RestModel from "model/rest"; import Api from "common/api"; import {DateTime} from "luxon"; -const SrcAuto = "" -const SrcManual = "manual" -const SrcLocation = "location" -const SrcImage = "image" -const SrcExif = "exif" -const SrcXmp = "xmp" -const SrcYml = "yml" -const SrcJson = "json" +const SrcAuto = ""; +const SrcManual = "manual"; +const SrcLocation = "location"; +const SrcImage = "image"; +const SrcExif = "exif"; +const SrcXmp = "xmp"; +const SrcYml = "yml"; +const SrcJson = "json"; class Photo extends RestModel { getDefaults() { @@ -85,13 +85,13 @@ class Photo extends RestModel { getColor() { switch (this.PhotoColor) { - case "brown": - case "black": - case "white": - case "grey": - return "grey lighten-2"; - default: - return this.PhotoColor + " lighten-4"; + case "brown": + case "black": + case "white": + case "grey": + return "grey lighten-2"; + default: + return this.PhotoColor + " lighten-4"; } }