rejetto forum

Software => HFS ~ HTTP File Server => Programmers corner => Topic started by: Mars on September 04, 2009, 09:59:21 PM

Title: macro rename little bug
Post by: Mars on September 04, 2009, 09:59:21 PM
main.pas
Quote
   if name = 'rename' then
      if renameFile(p, par(1))
      and not stopOnMacroRename then // should we stop recursion?
        try
          // by default, we'll stop after first stacked [on macro rename], but recursive=1 will remove this limit
          stopOnMacroRename:=isFalse(par('recursive'));
          runEventScript('on macro rename', toSA(['%old-name%',p,'%new-name%',par(1)]));
          spaceIf(TRUE);
        finally
          stopOnMacroRename:=FALSE;
        end
      else result:='';  // add by mars

Else ....when a rename failed, the macro is replaced by <div class=macroerror>macro error: ' ...
Title: Re: macro rename little bug
Post by: rejetto on September 05, 2009, 03:02:26 PM
thank you mars