[db,jsonapi] remove DB_FILES_USERMARK_MAX

This commit is contained in:
whatdoineed2do/Ray 2021-09-15 08:40:07 +01:00
parent d43ce017f5
commit 52d1ba7dd4
2 changed files with 1 additions and 6 deletions

View File

@ -150,8 +150,6 @@ enum user_mark {
USER_MARK_REVIEW = 4 USER_MARK_REVIEW = 4
}; };
#define DB_FILES_USERMARK_MAX UINT_MAX
/* Note that fields marked as integers in the metadata map in filescanner_ffmpeg must be uint32_t here */ /* Note that fields marked as integers in the metadata map in filescanner_ffmpeg must be uint32_t here */
struct media_file_info { struct media_file_info {

View File

@ -3351,10 +3351,7 @@ jsonapi_reply_library_tracks_put_byid(struct httpd_request *hreq)
if (ret < 0) if (ret < 0)
return HTTP_BADREQUEST; return HTTP_BADREQUEST;
if (uval >= 0 && uval <= DB_FILES_USERMARK_MAX) ret = db_file_usermark_update_byid(track_id, uval);
ret = db_file_usermark_update_byid(track_id, uval);
else
DPRINTF(E_WARN, L_WEB, "Ignoring invalid usermark value '%u' for track '%d'.\n", uval, track_id);
if (ret < 0) if (ret < 0)
return HTTP_INTERNAL; return HTTP_INTERNAL;