Frontend: Code clean-up #225

Signed-off-by: Michael Mayer <michael@liquidbytes.net>
This commit is contained in:
Michael Mayer 2020-03-28 18:18:05 +01:00
parent 0f5d7a7e42
commit a1feb1c99e

View file

@ -230,23 +230,23 @@ class Photo extends Abstract {
const values = this.getValues(true);
if(values.PhotoTitle) {
values.ModifiedTitle = true
values.ModifiedTitle = true;
}
if(values.Description) {
values.ModifiedDescription = true
values.ModifiedDescription = true;
}
if(values.PhotoLat || values.PhotoLng || values.PhotoAltitude || values.PhotoCountry) {
values.ModifiedLocation = true
values.ModifiedLocation = true;
}
if(values.TakenAt || values.TimeZone) {
values.ModifiedDate = true
values.ModifiedDate = true;
}
if(values.CameraID || values.LensID) {
values.ModifiedCamera = true
values.ModifiedCamera = true;
}
return Api.put(this.getEntityResource(), values).then((response) => Promise.resolve(this.setValues(response.data)));