Allow usePolicy to fetch missing policies

This commit is contained in:
Tom Moor
2022-08-25 10:06:44 +02:00
parent 983010b5d8
commit 60309975e0
32 changed files with 91 additions and 53 deletions

View File

@@ -18,7 +18,7 @@ type Props = {
function Actions({ collection }: Props) {
const { t } = useTranslation();
const can = usePolicy(collection.id);
const can = usePolicy(collection);
return (
<>

View File

@@ -20,7 +20,7 @@ type Props = {
function EmptyCollection({ collection }: Props) {
const { t } = useTranslation();
const can = usePolicy(collection.id);
const can = usePolicy(collection);
const collectionName = collection ? collection.name : "";
const [