Skip to content
Permalink
Browse files

small fix for previous commit :"fixes to creation of filename/path fr…

…om format"
  • Loading branch information
squentin committed Jan 23, 2010
1 parent c90727b commit 9210105ecc1b82506af6329ff4e5fbee5090e09e
Showing with 1 addition and 1 deletion.
  1. +1 −1 gmusicbrowser.pl
@@ -3994,7 +3994,7 @@ sub filenamefromformat
sub pathfromformat
{ my ($ID,$format,$basefolder,$icase)=@_;
my $path= defined $basefolder.SLASH ? $basefolder : '';
$path.=$1 if $format=~s#^([^$%]*$QSLASH)##; # move constant part of format in path
$path.=$1 if $format=~s#^([^\$%]*$QSLASH)##; # move constant part of format in path
$path= Songs::Get($ID,'path').SLASH.$path if $path!~m#^~?$QSLASH#o; # use song's path as base for relative paths
$path=~s#^~($QSLASH)#$ENV{HOME}$1#o; # replace leading ~/ by homedir
$path=~s#$QSLASH+\.?$QSLASH+#SLASH#goe; # remove repeated slashes and /./

0 comments on commit 9210105

Please sign in to comment.