Mark Subscriber::getCurrentWPUser as deprecated

[MAILPOET-3268]
This commit is contained in:
Jan Lysý
2021-03-13 20:31:08 +01:00
committed by Veljko V
parent 6f5f3bc6c5
commit 3b0af31b10

View File

@ -107,6 +107,9 @@ class Subscriber extends Model {
return (bool)$this->isWoocommerceUser;
}
/**
* @deprecated Use the version in \MailPoet\Subscribers\SubscribersRepository::getCurrentWPUser
*/
public static function getCurrentWPUser() {
$wpUser = WPFunctions::get()->wpGetCurrentUser();
if (empty($wpUser->ID)) {