Uma área de pesquisa sobre o WordPress para devs e autores do tema



rest_pre_update_setting ›

Desde4.7.0
Obsoleton/a
apply_filters( 'rest_pre_update_setting', false, $name, $request[ $name ], $args )
Parâmetros: (4)
  • (bool) $result Whether to override the default behavior for updating the value of a setting.
    Required: Yes
  • (string) $name Setting name (as shown in REST API responses).
    Required: Yes
  • (mixed) $value Updated setting value.
    Required: Yes
  • (array) $args Arguments passed to register_setting() for this setting.
    Required: Yes
Definido em:
Codex:

Filters whether to preempt a setting value update.

Allows hijacking the setting update logic and overriding the built-in behavior by returning true.





Fonte

$updated = apply_filters( 'rest_pre_update_setting', false, $name, $request[ $name ], $args );