summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2018-01-25 22:59:50 +0100
committerMorris Jobke <hey@morrisjobke.de>2018-01-25 22:59:50 +0100
commit464f024fa9501b2644a02198768d32f6d057f4bb (patch)
tree8cc0dae1a953c2e50f0c0df4176e59ac0c012e96
parentb9bbb894f8b01e000bb5e3a8a82db7bebad3ea00 (diff)
downloadnextcloud-server-464f024fa9501b2644a02198768d32f6d057f4bb.tar.gz
nextcloud-server-464f024fa9501b2644a02198768d32f6d057f4bb.zip
Use stripos instead of strpos(strtolower(), 'something')
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
-rw-r--r--apps/encryption/lib/Crypto/Crypt.php2
-rw-r--r--apps/workflowengine/lib/Controller/RequestTime.php2
2 files changed, 2 insertions, 2 deletions
diff --git a/apps/encryption/lib/Crypto/Crypt.php b/apps/encryption/lib/Crypto/Crypt.php
index 090ca6184d6..4d5c20ea75f 100644
--- a/apps/encryption/lib/Crypto/Crypt.php
+++ b/apps/encryption/lib/Crypto/Crypt.php
@@ -560,7 +560,7 @@ class Crypt {
$signaturePosition = strpos($meta, '00sig00');
// enforce signature for the new 'CTR' ciphers
- if ($signaturePosition === false && strpos(strtolower($cipher), 'ctr') !== false) {
+ if ($signaturePosition === false && stripos($cipher, 'ctr') !== false) {
throw new GenericEncryptionException('Missing Signature', $this->l->t('Missing Signature'));
}
diff --git a/apps/workflowengine/lib/Controller/RequestTime.php b/apps/workflowengine/lib/Controller/RequestTime.php
index dd0efa89b91..1a07ca20a4d 100644
--- a/apps/workflowengine/lib/Controller/RequestTime.php
+++ b/apps/workflowengine/lib/Controller/RequestTime.php
@@ -37,7 +37,7 @@ class RequestTime extends Controller {
if ($search !== '') {
$timezones = array_filter($timezones, function ($timezone) use ($search) {
- return strpos(strtolower($timezone), strtolower($search)) !== false;
+ return stripos($timezone, $search) !== false;
});
}