feat: Refine trail category model (#1059)
* feat: advanced trail categories * rename remote_category * fix merge issues * subcategories for plugins mapping * fix refresh * remove vertical trail filter category scrolling * cleanup * add confirm modal for disabling a category * Fix federation issues * fix review findings * redesign category settings page * remove prio badge * fix subcategory badge layout * optimize subcategory settings layout * further settings page layout optimization * fix subcategory icon position * fix * update docs --------- Co-authored-by: Christian Beutel <>
This commit is contained in:
@@ -682,17 +682,21 @@ func processCreateOrUpdateSummitLogActivity(activity pub.Activity, app core.App,
|
||||
}
|
||||
}
|
||||
|
||||
if len(photoURLs) > 0 {
|
||||
photos := make([]*filesystem.File, len(photoURLs))
|
||||
for i, purl := range photoURLs {
|
||||
if len(photoURLs) == 0 {
|
||||
record.Set("photos", []*filesystem.File{})
|
||||
} else {
|
||||
photos := []*filesystem.File{}
|
||||
for _, purl := range photoURLs {
|
||||
photo, err := filesystem.NewFileFromURL(context.Background(), purl)
|
||||
if err != nil {
|
||||
continue
|
||||
}
|
||||
photos[i] = photo
|
||||
photos = append(photos, photo)
|
||||
}
|
||||
|
||||
record.Set("photos", photos)
|
||||
if len(photos) > 0 {
|
||||
record.Set("photos", photos)
|
||||
}
|
||||
}
|
||||
|
||||
if gpxURL != "" {
|
||||
|
||||
Reference in New Issue
Block a user