Skip to content

Commit d679110

Browse files
committed
Add tag to the cloudinary_allow_glb_upload hook
1 parent 4e9b891 commit d679110

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

php/media/class-gallery.php

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -694,14 +694,17 @@ public function setup_hooks() {
694694
add_filter( 'cloudinary_admin_pages', array( $this, 'register_settings' ) );
695695

696696
/**
697-
* Filter the media context query.
697+
* Filter to allow GLB 3D model files to be uploaded.
698698
*
699-
* @hook cloudinary_media_context_query
700-
* @since 3.2.0
699+
* WARNING: This is an experimental hook. The only place where GLB files can be used
700+
* is in the Cloudinary Gallery block.
701701
*
702-
* @param $media_context_query {string} The default media context query.
702+
* @hook cloudinary_allow_glb_upload
703+
* @since 3.2.6
703704
*
704-
* @return {string}
705+
* @param bool $allow_glb_upload Whether to allow GLB files to be uploaded.
706+
*
707+
* @return bool
705708
*/
706709
if ( apply_filters( 'cloudinary_allow_glb_upload', false ) ) {
707710
add_filter( 'upload_mimes', array( $this, 'add_glb_mime' ), 20, 1 );

0 commit comments

Comments
 (0)