Skip to content

Commit cb6e558

Browse files
Fixes a but that prevented has_permission from providing the arguments from the callback
1 parent b7010de commit cb6e558

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

lib/Abstracts/Meta_Record_Type.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ public function sanitize( $meta_value, $meta_key, $object_type ){
4242
*
4343
* @return mixed
4444
*/
45-
abstract public function has_permission();
45+
abstract public function has_permission( $allowed, $meta_key, $object_id, $user_id, $cap, $caps );
4646

4747
/**
4848
* Adds the metadata.

lib/Factories/Meta_Record_Type_Instance.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public function sanitize( $meta_value, $meta_key, $object_type ) {
3030
return parent::sanitize( $meta_value, $meta_key, $object_type );
3131
}
3232

33-
public function has_permission() {
33+
public function has_permission( $allowed, $meta_key, $object_id, $user_id, $cap, $caps ) {
3434
return $this->set_callable( $this->has_permission_callback );
3535
}
3636

0 commit comments

Comments
 (0)