aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xapp/Controllers/feedController.php2
-rw-r--r--app/Controllers/subscriptionController.php2
-rw-r--r--phpcs.xml5
3 files changed, 7 insertions, 2 deletions
diff --git a/app/Controllers/feedController.php b/app/Controllers/feedController.php
index 26e3caa3c..48a829b10 100755
--- a/app/Controllers/feedController.php
+++ b/app/Controllers/feedController.php
@@ -209,7 +209,7 @@ class FreshRSS_feed_Controller extends FreshRSS_ActionController {
}
}
}
- if(!empty($headers)) {
+ if (!empty($headers)) {
$headers = array_filter(array_map('trim', $headers));
$opts[CURLOPT_HTTPHEADER] = array_merge($headers, $opts[CURLOPT_HTTPHEADER] ?? []);
}
diff --git a/app/Controllers/subscriptionController.php b/app/Controllers/subscriptionController.php
index 43f6aad11..04e8bdf62 100644
--- a/app/Controllers/subscriptionController.php
+++ b/app/Controllers/subscriptionController.php
@@ -190,7 +190,7 @@ class FreshRSS_subscription_Controller extends FreshRSS_ActionController {
}
}
- if(!empty($headers)) {
+ if (!empty($headers)) {
$headers = array_filter(array_map('trim', $headers));
$opts[CURLOPT_HTTPHEADER] = array_merge($headers, $opts[CURLOPT_HTTPHEADER] ?? []);
}
diff --git a/phpcs.xml b/phpcs.xml
index 5b29b81a2..05eeefe66 100644
--- a/phpcs.xml
+++ b/phpcs.xml
@@ -88,12 +88,17 @@
<exclude-pattern>*\.phtml$</exclude-pattern>
</rule>
<!-- <rule ref="Squiz.Commenting.ClassComment.Missing"/> --><!-- Consider adding -->
+
<rule ref="Squiz.ControlStructures.ControlSignature">
<include-pattern>*\.phtml$</include-pattern>
<properties>
<property name="requiredSpacesBeforeColon" value="0" />
</properties>
</rule>
+ <rule ref="Squiz.ControlStructures.ControlSignature">
+ <include-pattern>*\.php$</include-pattern>
+ </rule>
+
<rule ref="Squiz.ControlStructures.ControlSignature.NewlineAfterOpenBrace">
<exclude-pattern>*\.phtml$</exclude-pattern>
</rule>