Skip to content

Commit

Permalink
Fix creation date for tags
Browse files Browse the repository at this point in the history
  • Loading branch information
nikolaydimitrov committed Nov 17, 2023
1 parent 9d6e44b commit cfbd40b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions handlers/tag.go
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,8 @@ func TagList(c *gin.Context, user *models.User) {
defer rows.Close()
tags := Tags{}
mimeType := ""
var assetId, createdAt uint64
var assetId uint64
var createdAt int64
var gpsLat, gpsLong *float64
var area, city, country *string
favourite := false
Expand All @@ -98,8 +99,9 @@ func TagList(c *gin.Context, user *models.User) {
tags.add(tagTypePlace, country, assetId)
// Add time tags, e.g "2023", "April", "22"
tmpAsset := &models.Asset{
GpsLat: gpsLat,
GpsLong: gpsLong,
CreatedAt: createdAt,
GpsLat: gpsLat,
GpsLong: gpsLong,
}
// Time zone for the given GPS coordinates is used
year, month, day := tmpAsset.GetCreatedTimeInLocation().Date()
Expand Down

0 comments on commit cfbd40b

Please sign in to comment.