]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - plugins/Favorite/actions/apifavoritecreate.php
pluginified most of hasFave, getFaves and related calls
[quix0rs-gnu-social.git] / plugins / Favorite / actions / apifavoritecreate.php
index 607fb76edc3dcc931442e8c102fec990cda8ca29..dd4fbd27957468d391d23a4901c6218d18fb069c 100644 (file)
@@ -118,7 +118,7 @@ class ApiFavoriteCreateAction extends ApiAuthAction
 
         // Note: Twitter lets you fave things repeatedly via API.
 
-        if ($this->user->hasFave($this->notice)) {
+        if (Fave::existsForProfile($this->notice, $this->scoped)) {
             $this->clientError(
                 // TRANS: Client error displayed when trying to mark a notice favourite that already is a favourite.
                 _('This status is already a favorite.'),