Explorar el Código

Deal with some SMB escape sequences in the sort name

Zachary Kotlarek hace 13 años
padre
commit
9033529559
Se han modificado 1 ficheros con 2 adiciones y 0 borrados
  1. 2 0
      web/includes/util.php

+ 2 - 0
web/includes/util.php

@@ -44,6 +44,8 @@ function isJunk($path) {
 function sortTitle($name) {
 function sortTitle($name) {
 	$name = preg_replace('/^The\s+/i', '', $name);
 	$name = preg_replace('/^The\s+/i', '', $name);
 	$name = preg_replace('/^A\s+/i', '', $name);
 	$name = preg_replace('/^A\s+/i', '', $name);
+	$name = preg_replace('/\xEF\x80\xA9$/', '.', $name);
+	$name = preg_replace('/\xEF\x80\xA5/', '?', $name);
 	return $name;
 	return $name;
 }
 }