mirror of
https://github.com/pierre42100/ComunicAPI
synced 2025-06-19 00:25:18 +00:00
Get a post movie ID securely
This commit is contained in:
@ -54,6 +54,16 @@ class Movies {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Check whether a movie specified by its ID exists or not
|
||||
*
|
||||
* @param int $movieID The ID of the movie to check
|
||||
* @return bool TRUE if the movie exists / false else
|
||||
*/
|
||||
function exist(int $movieID) : bool {
|
||||
return CS::get()->db->count($this::MOVIES_TABLE, "WHERE ID = ?", array($movieID)) > 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* Parse a video informations
|
||||
*
|
||||
|
Reference in New Issue
Block a user