Skip to content

Commit ca81558

Browse files
committed
Use correct ID for token meta
1 parent 756a2c9 commit ca81558

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

inc/tokens/class-access-token.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public static function create( Client $client, WP_User $user ) {
4848
$key = wp_generate_password( static::KEY_LENGTH, false );
4949
$meta_key = static::META_PREFIX . $key;
5050

51-
$result = add_post_meta( $client->get_id(), wp_slash( $meta_key ), wp_slash( $data ), true );
51+
$result = add_post_meta( $client->get_post_id(), wp_slash( $meta_key ), wp_slash( $data ), true );
5252
if ( ! $result ) {
5353
return new WP_Error(
5454
'oauth2.tokens.access_token.create.could_not_create',

0 commit comments

Comments
 (0)