fix favicon, playlist subscription only
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
export const PLAYLIST_CREATION_SUBSCRIPTION_MESSAGE =
|
||||
'La création de playlist est réservée aux abonnés.'
|
||||
|
||||
export const canCreatePlaylist = (hasActiveSubscription = false) => hasActiveSubscription === true
|
||||
|
||||
export const assertCanCreatePlaylist = (hasActiveSubscription = false) => {
|
||||
if (!canCreatePlaylist(hasActiveSubscription)) {
|
||||
throw new Error(PLAYLIST_CREATION_SUBSCRIPTION_MESSAGE)
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user