Skip to content

Commit ae0a1d3

Browse files
committed
Add tag to the cloudinary_allow_glb_upload hook
1 parent d6a0e39 commit ae0a1d3

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

php/media/class-gallery.php

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

705705
/**
706-
* Filter the media context query.
706+
* Filter to allow GLB 3D model files to be uploaded.
707707
*
708-
* @hook cloudinary_media_context_query
709-
* @since 3.2.0
708+
* WARNING: This is an experimental hook. The only place where GLB files can be used
709+
* is in the Cloudinary Gallery block.
710710
*
711-
* @param $media_context_query {string} The default media context query.
711+
* @hook cloudinary_allow_glb_upload
712+
* @since 3.2.6
712713
*
713-
* @return {string}
714+
* @param bool $allow_glb_upload Whether to allow GLB files to be uploaded.
715+
*
716+
* @return bool
714717
*/
715718
if ( apply_filters( 'cloudinary_allow_glb_upload', false ) ) {
716719
add_filter( 'upload_mimes', array( $this, 'add_glb_mime' ), 20, 1 );

0 commit comments

Comments
 (0)