- Timestamp:
- 05/01/2020 02:24:42 PM (6 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/SimplePie/Content/Type/Sniffer.php
r22798 r47733 6 6 * Takes the hard work out of managing a complete RSS/Atom solution. 7 7 * 8 * Copyright (c) 2004-201 2, Ryan Parman, GeoffreySneddon, Ryan McCue, and contributors8 * Copyright (c) 2004-2016, Ryan Parman, Sam Sneddon, Ryan McCue, and contributors 9 9 * All rights reserved. 10 10 * … … 34 34 * 35 35 * @package SimplePie 36 * @version 1.3.1 37 * @copyright 2004-2012 Ryan Parman, Geoffrey Sneddon, Ryan McCue 36 * @copyright 2004-2016 Ryan Parman, Sam Sneddon, Ryan McCue 38 37 * @author Ryan Parman 39 * @author GeoffreySneddon38 * @author Sam Sneddon 40 39 * @author Ryan McCue 41 40 * @link http://simplepie.org/ SimplePie … … 122 121 return $return; 123 122 } 124 else 125 { 126 return $official; 127 } 123 124 return $official; 128 125 } 129 126 elseif ($official === 'text/html') … … 131 128 return $this->feed_or_html(); 132 129 } 133 else 134 { 135 return $official; 136 } 137 } 138 else 139 { 140 return $this->unknown(); 141 } 130 131 return $official; 132 } 133 134 return $this->unknown(); 142 135 } 143 136 … … 160 153 return 'application/octect-stream'; 161 154 } 162 else 163 { 164 return 'text/plain'; 165 } 155 156 return 'text/plain'; 166 157 } 167 158 … … 209 200 return 'image/vnd.microsoft.icon'; 210 201 } 211 else 212 { 213 return $this->text_or_binary(); 214 } 202 203 return $this->text_or_binary(); 215 204 } 216 205 … … 243 232 return 'image/vnd.microsoft.icon'; 244 233 } 245 else 246 { 247 return false; 248 } 234 235 return false; 249 236 } 250 237 … … 257 244 { 258 245 $len = strlen($this->file->body); 259 $pos = strspn($this->file->body, "\x09\x0A\x0D\x20 ");246 $pos = strspn($this->file->body, "\x09\x0A\x0D\x20\xEF\xBB\xBF"); 260 247 261 248 while ($pos < $len) … … 330 317 } 331 318 } 332
Note:
See TracChangeset
for help on using the changeset viewer.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)