diff --git a/functionMap.php b/functionMap.php index ba51871..0cb4cbc 100644 --- a/functionMap.php +++ b/functionMap.php @@ -156,6 +156,7 @@ 'get_terms' => ["(\$args is array{fields: 'count'}&array ? numeric-string : (\$args is array{fields: 'names'|'slugs'}&array ? list : (\$args is array{fields: 'id=>name'|'id=>slug'}&array ? array : (\$args is array{fields: 'id=>parent'}&array ? array : (\$args is array{fields: 'ids'|'tt_ids'}&array ? list : array)))))|\WP_Error", 'deprecated' => "''"], 'get_the_author' => [null, 'deprecated' => "''"], 'get_the_permalink' => ['($post is \WP_Post ? string : string|false)'], + 'get_transient' => [null, '@phpstan-impure' => ''], 'get_user' => ['($user_id is int ? false : \WP_User|false)'], 'get_user_by' => ["(\$field is 'id'|'ID' ? (\$value is int ? false : \WP_User|false) : \WP_User|false)"], 'get_user_option' => [null, 'deprecated' => "''"], @@ -295,6 +296,7 @@ 'wp_list_pages' => ['($args is array{echo: false}&array ? string : void)'], 'wp_list_post_revisions' => ['void', 'type' => "'all'|'revision'|'autosave'"], 'wp_loginout' => ['($display is true ? void : string)'], + 'wp_mail' => [null, '@phpstan-impure' => ''], 'wp_media_insert_url_form' => ['non-falsy-string'], 'wp_nav_menu_manage_columns' => ["array{_title: string, cb: '', link-target: string, title-attribute: string, css-classes: string, xfn: string, description: string}"], 'wp_next_scheduled' => [null, 'args' => $cronArgsType], diff --git a/wordpress-stubs.php b/wordpress-stubs.php index 919ec08..3649201 100644 --- a/wordpress-stubs.php +++ b/wordpress-stubs.php @@ -133044,6 +133044,7 @@ function delete_transient($transient) * * @param string $transient Transient name. Expected to not be SQL-escaped. * @return mixed Value of transient. + * @phpstan-impure */ function get_transient($transient) { @@ -133743,6 +133744,7 @@ function cache_users($user_ids) * @param string|string[] $attachments Optional. Paths to files to attach. * @param string|string[] $embeds Optional. Paths to files to embed. * @return bool Whether the email was sent successfully. + * @phpstan-impure */ function wp_mail($to, $subject, $message, $headers = '', $attachments = array(), $embeds = array()) {