2018-11-06 19:02:03 +01:00
|
|
|
/*
|
2021-11-25 14:52:26 +01:00
|
|
|
Package entity provides models for storing index information based on the GORM library.
|
2018-11-06 19:02:03 +01:00
|
|
|
|
|
|
|
See http://gorm.io/docs/ for more information about GORM.
|
|
|
|
|
|
|
|
Additional information concerning data storage can be found in our Developer Guide:
|
|
|
|
|
|
|
|
https://github.com/photoprism/photoprism/wiki/Storage
|
|
|
|
*/
|
2019-12-11 16:55:18 +01:00
|
|
|
package entity
|
2019-12-11 19:11:44 +01:00
|
|
|
|
|
|
|
import (
|
|
|
|
"github.com/photoprism/photoprism/internal/event"
|
|
|
|
)
|
|
|
|
|
|
|
|
var log = event.Log
|
2020-12-05 00:13:44 +01:00
|
|
|
var GeoApi = "places"
|
2019-12-11 19:11:44 +01:00
|
|
|
|
2021-11-25 14:52:26 +01:00
|
|
|
// Log logs the error if any and keeps quiet otherwise.
|
|
|
|
func Log(model, action string, err error) {
|
|
|
|
if err != nil {
|
|
|
|
log.Errorf("%s: %s (%s)", model, err, action)
|
2019-12-11 19:11:44 +01:00
|
|
|
}
|
|
|
|
}
|