From 15899f2077cb9f64266414b6cb41916d3ddc43c9 Mon Sep 17 00:00:00 2001 From: mappu Date: Sun, 30 Sep 2018 19:24:00 +1300 Subject: [PATCH] remove dead code --- shunt_tags | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/shunt_tags b/shunt_tags index 9ba5425..62fb39b 100755 --- a/shunt_tags +++ b/shunt_tags @@ -64,7 +64,7 @@ function fixup($input) { } while (! array_key_exists($tmp, $seen)); return $tmp; }; - + // Some files using underscore instead of space // Except - preserve "G_P", that's a known sub group // Iterate until fixed point @@ -159,12 +159,7 @@ function fixup($input) { return $tmp; }); - /* - // Move tags from middle to end - $tmp = $fixed_point_iterate($tmp, function($tmp) { - return preg_replace('~([^\[\]]+)(\[[^\]]+?\])([^\[\]]+)~', '\1\3\2', $tmp); - }); - */ + // Cleanup commas inside tags ( [720p,Bluray] => [720p Bluray] ) $tmp = preg_replace_callback('~\[(.+)\]~', function($matches) { return str_replace(',', ' ', $matches[0]); }, $tmp);