Use \. in extension regexes
authorMarius Gavrilescu <marius@ieval.ro>
Sat, 25 Oct 2014 09:34:03 +0000 (12:34 +0300)
committerMarius Gavrilescu <marius@ieval.ro>
Sat, 25 Oct 2014 09:34:03 +0000 (12:34 +0300)
lib/App/MusicExpo.pm

index e9c0b9579e5556e2839a860ce2aa727ec46bf549..7b5f4e2f46d7ba70d0bcb3b7852f03d1b81afb9c 100644 (file)
@@ -106,9 +106,9 @@ sub run {
        my %files;
        for my $file (@ARGV) {
                my $info;
-               $info = thaw flacinfo $file if $file =~ /.flac$/i;
-               $info = thaw mp3info $file if $file =~ /.mp3$/i;
-               $info = thaw vorbisinfo $file if $file =~ /.og(?:g|a)$/i;
+               $info = thaw flacinfo $file if $file =~ /\.flac$/i;
+               $info = thaw mp3info $file if $file =~ /\.mp3$/i;
+               $info = thaw vorbisinfo $file if $file =~ /\.og(?:g|a)$/i;
                next unless defined $info;
                my $basename = fileparse $file, '.flac', '.mp3', '.ogg', '.oga';
                $files{$basename} //= [];
This page took 0.011764 seconds and 4 git commands to generate.