rest_avatar_sizes

过滤钩子


apply_filters( 'rest_avatar_sizes', array( 24, 48, 96 )
参数
  • (int[])
    $sizes
    An array of int values that are the pixel sizes for avatars.
    Default `[ 24, 48, 96 ]`.
    Required:
定义位置
  • wp-includes/rest-api.php
    , line 1242
引入
4.4.0
弃用

Filters the REST avatar sizes.

Use this filter to adjust the array of sizes returned by the
rest_get_avatar_sizes function.

return apply_filters( 'rest_avatar_sizes', array( 24, 48, 96 ) );