mirror of
https://github.com/owntone/owntone-server.git
synced 2025-01-14 08:15:02 -05:00
Make sure that 'Library' isn't editable
This commit is contained in:
parent
c67af0fb50
commit
23e2bab36b
@ -488,6 +488,11 @@ int db_sql_edit_playlist(char **pe, int id, char *name, char *clause) {
|
|||||||
if((name == NULL) && (clause == NULL))
|
if((name == NULL) && (clause == NULL))
|
||||||
return DB_E_SUCCESS; /* I guess?? */
|
return DB_E_SUCCESS; /* I guess?? */
|
||||||
|
|
||||||
|
if(id == 1) { /* can't edit the library query */
|
||||||
|
db_get_error(pe,DB_E_INVALID_PLAYLIST);
|
||||||
|
reuturn DB_E_INVALID_PLAYLIST;
|
||||||
|
}
|
||||||
|
|
||||||
/* first, check the playlist */
|
/* first, check the playlist */
|
||||||
result=db_sql_fetch_int(pe,&playlist_type,
|
result=db_sql_fetch_int(pe,&playlist_type,
|
||||||
"select type from playlists where id=%d",id);
|
"select type from playlists where id=%d",id);
|
||||||
|
Loading…
Reference in New Issue
Block a user