Jelajahi Sumber

SimplePie force HTTPS, another approach

https://github.com/FreshRSS/FreshRSS/issues/1083
Alexandre Alapetite 10 tahun lalu
induk
melakukan
74ef8d9b15
2 mengubah file dengan 3 tambahan dan 2 penghapusan
  1. 1 1
      lib/SimplePie/SimplePie/Misc.php
  2. 2 1
      lib/SimplePie/SimplePie/Sanitize.php

+ 1 - 1
lib/SimplePie/SimplePie/Misc.php

@@ -97,7 +97,7 @@ class SimplePie_Misc
 		{
 		{
 			return false;
 			return false;
 		}
 		}
-		return SimplePie_Misc::https_url($iri->get_uri());
+		return $iri->get_uri();
 	}
 	}
 
 
 	/**
 	/**

+ 2 - 1
lib/SimplePie/SimplePie/Sanitize.php

@@ -451,7 +451,8 @@ class SimplePie_Sanitize
 					if ($element->hasAttribute($attribute))
 					if ($element->hasAttribute($attribute))
 					{
 					{
 						$value = $this->registry->call('Misc', 'absolutize_url', array($element->getAttribute($attribute), $this->base));
 						$value = $this->registry->call('Misc', 'absolutize_url', array($element->getAttribute($attribute), $this->base));
-						if ($value !== false)
+						$value = SimplePie_Misc::https_url($value);	//FreshRSS
+						if ($value)
 						{
 						{
 							$element->setAttribute($attribute, $value);
 							$element->setAttribute($attribute, $value);
 						}
 						}