{"thread":{"id":"16900","subject":"[PATCH] Git.pm: let a \"false\" Directory parameter (such as \"0\") be used correctly by the constructor\"","startedAt":"2008-12-29T00:25:00Z","lastAt":"2009-01-02T08:37:34Z","messageCount":3,"participants":["Philippe Bruhat (BooK)","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"98853","messageId":"1230510300-7854-1-git-send-email-book@cpan.org","threadId":"16900","inReplyTo":null,"subject":"[PATCH] Git.pm: let a \"false\" Directory parameter (such as \"0\") be used correctly by the constructor\"","fromName":"Philippe Bruhat (BooK)","fromEmail":"book@cpan.org","sentAt":"2008-12-29T00:25:00Z","receivedAt":"2008-12-29T00:25:00Z","isPatch":true,"sender":{"key":"book@cpan.org","avatar":"https://avatars.githubusercontent.com/u/44421?v=4"},"body":"---\n perl/Git.pm |    7 ++++---\n 1 files changed, 4 insertions(+), 3 deletions(-)\n\ndiff --git a/perl/Git.pm b/perl/Git.pm\nindex 8392a68..ad0f530 100644\n--- a/perl/Git.pm\n+++ b/perl/Git.pm\n@@ -166,11 +166,12 @@ sub repository {\n \t\t}\n \t}\n \n-\tif (not defined $opts{Repository} and not defined $opts{WorkingCopy}) {\n-\t\t$opts{Directory} ||= '.';\n+\tif (not defined $opts{Repository} and not defined $opts{WorkingCopy}\n+\t\tand not defined $opts{Directory}) {\n+\t\t$opts{Directory} = '.';\n \t}\n \n-\tif ($opts{Directory}) {\n+\tif (defined $opts{Directory}) {\n \t\t-d $opts{Directory} or throw Error::Simple(\"Directory not found: $!\");\n \n \t\tmy $search = Git->repository(WorkingCopy => $opts{Directory});\n-- \n1.6.0.3.517.g759a\n"},{"id":"99108","messageId":"7vwsdeivx9.fsf@gitster.siamese.dyndns.org","threadId":"16900","inReplyTo":"1230510300-7854-1-git-send-email-book@cpan.org","subject":"Re: [PATCH] Git.pm: let a \"false\" Directory parameter (such as \"0\") be used correctly by the constructor\"","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-01-01T21:00:18Z","receivedAt":"2009-01-01T21:00:18Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Philippe Bruhat (BooK)\" <book@cpan.org> writes:\n\n> ---\n>  perl/Git.pm |    7 ++++---\n>  1 files changed, 4 insertions(+), 3 deletions(-)\n\nLacks sign-off and description but otherwise looks good.  Will queue to\n'pu' to leave you a chance to re-send.\n\n    commit b29b1ae7442cd7c1c78e38b7d980905944ec31e0\n    Author: Philippe Bruhat (BooK) <book@cpan.org>\n    Date:   Mon Dec 29 01:25:00 2008 +0100\n\n        Git.pm: correctly handle directory name that evaluates to \"false\"\n\n        The repository constructor mistakenly rewrote a Directory parameter that\n        Perl happens to evaluate to false (e.g. \"0\") to \".\".\n\n\nThanks.\n"},{"id":"99151","messageId":"20090102083734.GB25518@plop","threadId":"16900","inReplyTo":"7vwsdeivx9.fsf@gitster.siamese.dyndns.org","subject":"Re: [PATCH] Git.pm: let a \"false\" Directory parameter (such as \"0\") be used correctly by the constructor\"","fromName":"Philippe Bruhat (BooK)","fromEmail":"book@cpan.org","sentAt":"2009-01-02T08:37:34Z","receivedAt":"2009-01-02T08:37:34Z","isPatch":true,"sender":{"key":"book@cpan.org","avatar":"https://avatars.githubusercontent.com/u/44421?v=4"},"body":"On Thu, Jan 01, 2009 at 01:00:18PM -0800, Junio C Hamano wrote:\n> \"Philippe Bruhat (BooK)\" <book@cpan.org> writes:\n> \n> > ---\n> >  perl/Git.pm |    7 ++++---\n> >  1 files changed, 4 insertions(+), 3 deletions(-)\n> \n> Lacks sign-off and description but otherwise looks good.  Will queue to\n> 'pu' to leave you a chance to re-send.\n\nYeah, I noticed the lack of Sign-off right after sending. I'll re-send.\n\n-- \n Philippe Bruhat (BooK)\n\n A reputation is only as good as the truth beneath it, if any.\n                                    (Moral from Groo The Wanderer #91 (Epic))\n"}]}