summaryrefslogtreecommitdiff
path: root/include/functions.php
diff options
context:
space:
mode:
Diffstat (limited to 'include/functions.php')
-rw-r--r--include/functions.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/functions.php b/include/functions.php
index 397605c5a..cf35d6fa2 100644
--- a/include/functions.php
+++ b/include/functions.php
@@ -3788,7 +3788,7 @@
* @return string Absolute URL
*/
function rewrite_relative_url($url, $rel_url) {
- if (strpos($rel_url, "magnet:") === 0) {
+ if (strpos($rel_url, ":") !== false) {
return $rel_url;
} else if (strpos($rel_url, "://") !== false) {
return $rel_url;
@@ -3958,6 +3958,7 @@
$reg_qpart = "REGEXP";
foreach ($filter["rules"] AS $rule) {
+ $rule['reg_exp'] = str_replace('/', '\/', $rule["reg_exp"]);
$regexp_valid = preg_match('/' . $rule['reg_exp'] . '/',
$rule['reg_exp']) !== FALSE;