From a80fb40be3f71e42624f05e79414cd3d248c6079 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A9vin=20Dunglas?= Date: Tue, 17 Nov 2015 00:29:15 +0100 Subject: [PATCH] Fix CS --- spec/SocialShare/SocialShareSpec.php | 2 +- src/SocialShare/Provider/Facebook.php | 6 +++--- src/SocialShare/Provider/Google.php | 6 +++--- src/SocialShare/Provider/LinkedIn.php | 4 ++-- src/SocialShare/Provider/Pinterest.php | 8 ++++---- src/SocialShare/Provider/ScoopIt.php | 6 +++--- src/SocialShare/Provider/StumbleUpon.php | 6 +++--- src/SocialShare/Provider/Tumblr.php | 6 +++--- src/SocialShare/Provider/Twitter.php | 6 +++--- 9 files changed, 25 insertions(+), 25 deletions(-) diff --git a/spec/SocialShare/SocialShareSpec.php b/spec/SocialShare/SocialShareSpec.php index ae21c7c..d7df57e 100644 --- a/spec/SocialShare/SocialShareSpec.php +++ b/spec/SocialShare/SocialShareSpec.php @@ -74,7 +74,7 @@ public function it_delays_update($cache, $provider) $numberOfCalls = 0; $cache->fetch('test_http://dunglas.fr')->will(function () use ($cache, &$numberOfCalls) { if ($numberOfCalls === 0) { - $numberOfCalls++; + ++$numberOfCalls; return array(2, new \DateTime('-1 day')); } diff --git a/src/SocialShare/Provider/Facebook.php b/src/SocialShare/Provider/Facebook.php index c3ad190..1197c45 100644 --- a/src/SocialShare/Provider/Facebook.php +++ b/src/SocialShare/Provider/Facebook.php @@ -23,7 +23,7 @@ class Facebook implements ProviderInterface const API_URL = 'https://graph.facebook.com/?id=%s'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -31,7 +31,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -39,7 +39,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) { diff --git a/src/SocialShare/Provider/Google.php b/src/SocialShare/Provider/Google.php index 2feae58..964006c 100644 --- a/src/SocialShare/Provider/Google.php +++ b/src/SocialShare/Provider/Google.php @@ -23,7 +23,7 @@ class Google implements ProviderInterface const IFRAME_URL = 'https://plusone.google.com/_/+1/fastbutton?url=%s'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -31,7 +31,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -39,7 +39,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) { diff --git a/src/SocialShare/Provider/LinkedIn.php b/src/SocialShare/Provider/LinkedIn.php index 61cc943..66a0caa 100644 --- a/src/SocialShare/Provider/LinkedIn.php +++ b/src/SocialShare/Provider/LinkedIn.php @@ -23,7 +23,7 @@ class LinkedIn implements ProviderInterface const API_URL = 'https://www.linkedin.com/countserv/count/share?url=%s&format=json'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -52,7 +52,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) { diff --git a/src/SocialShare/Provider/Pinterest.php b/src/SocialShare/Provider/Pinterest.php index d17cc06..bcbe688 100644 --- a/src/SocialShare/Provider/Pinterest.php +++ b/src/SocialShare/Provider/Pinterest.php @@ -23,7 +23,7 @@ class Pinterest implements ProviderInterface const API_URL = 'https://api.pinterest.com/v1/urls/count.json?url=%s'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -31,7 +31,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -41,11 +41,11 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) { - $data = json_decode(preg_replace('/^receiveCount\((.*)\)$/', "\\1", file_get_contents(sprintf(self::API_URL, urlencode($url))))); + $data = json_decode(preg_replace('/^receiveCount\((.*)\)$/', '\\1', file_get_contents(sprintf(self::API_URL, urlencode($url))))); return intval($data->count); } diff --git a/src/SocialShare/Provider/ScoopIt.php b/src/SocialShare/Provider/ScoopIt.php index 175ffd8..0899242 100644 --- a/src/SocialShare/Provider/ScoopIt.php +++ b/src/SocialShare/Provider/ScoopIt.php @@ -25,7 +25,7 @@ class ScoopIt implements ProviderInterface const DTD = ''; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -33,7 +33,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -41,7 +41,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) { diff --git a/src/SocialShare/Provider/StumbleUpon.php b/src/SocialShare/Provider/StumbleUpon.php index fbbb70b..6d04e3f 100644 --- a/src/SocialShare/Provider/StumbleUpon.php +++ b/src/SocialShare/Provider/StumbleUpon.php @@ -23,7 +23,7 @@ class StumbleUpon implements ProviderInterface const API_URL = 'https://www.stumbleupon.com/services/1.01/badge.getinfo?url=%s'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -31,7 +31,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -41,7 +41,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) { diff --git a/src/SocialShare/Provider/Tumblr.php b/src/SocialShare/Provider/Tumblr.php index 31ecbe8..2866f8e 100644 --- a/src/SocialShare/Provider/Tumblr.php +++ b/src/SocialShare/Provider/Tumblr.php @@ -24,7 +24,7 @@ class Tumblr implements ProviderInterface const SHARE_URL = 'https://www.tumblr.com/share/link?%s'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -32,7 +32,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -42,7 +42,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} * * @throws UnsupportedOperationException */ diff --git a/src/SocialShare/Provider/Twitter.php b/src/SocialShare/Provider/Twitter.php index b327d45..bfb66ad 100644 --- a/src/SocialShare/Provider/Twitter.php +++ b/src/SocialShare/Provider/Twitter.php @@ -23,7 +23,7 @@ class Twitter implements ProviderInterface const API_URL = 'https://cdn.api.twitter.com/1/urls/count.json?url=%s'; /** - * {@inheritDoc} + * {@inheritdoc} */ public function getName() { @@ -31,7 +31,7 @@ public function getName() } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getLink($url, array $options = array()) { @@ -41,7 +41,7 @@ public function getLink($url, array $options = array()) } /** - * {@inheritDoc} + * {@inheritdoc} */ public function getShares($url) {