Skip to content

Commit

Permalink
remove not needed check
Browse files Browse the repository at this point in the history
  • Loading branch information
matiasbenedetto committed Feb 28, 2024
1 parent fe28f6d commit 29d01c4
Showing 1 changed file with 0 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@ import {
FlexItem,
privateApis as componentsPrivateApis,
} from '@wordpress/components';
import { store as coreStore } from '@wordpress/core-data';
import { useSelect } from '@wordpress/data';
import { useContext, useState } from '@wordpress/element';

/**
Expand All @@ -32,14 +30,6 @@ const { ProgressBar } = unlock( componentsPrivateApis );
function UploadFonts() {
const { installFont, notice, setNotice } = useContext( FontLibraryContext );
const [ isUploading, setIsUploading ] = useState( false );
const canUserCreate = useSelect( ( select ) => {
const { canUser } = select( coreStore );
return canUser( 'create', 'font-families' );
}, [] );

if ( ! canUserCreate ) {
return null;
}

const handleDropZone = ( files ) => {
handleFilesUpload( files );
Expand Down

0 comments on commit 29d01c4

Please sign in to comment.