[PATCH] archive: make sure prefix is a string
Andreas Freimuth
andreas.freimuth at united-bits.de
Sun Jul 31 16:29:34 CDT 2011
On 07/31/2011 10:46 PM, Mads Kiilerich wrote:
> Yes, we have prefix=None in the function definition, but is the
> function ever called without prefix set to a string?
No, probably not. I was calling it from a hook (until I remembered it is
recommended to use the mercurial.commands module)
> What you have found might not be a bug but just an indication that
> prefix is a mandatory parameter unless kind='files'.
As long as a destination is given, prefix may be None.
> However, if the default value for prefix should be '', then why not
> just set it as default instead of None?
Well. I thought about it, but I liked the idea to say prefix=None for no
prefix, what is possible except for kind='files'.
More information about the Mercurial-devel
mailing list