Mercurial > hg
changeset 13006:ea68947ad0ce stable
httprepo: remove is-comparison with string literal
An identity check between a variable and a string literal was added to
the pushkey implementation in 6bd9778ae749. While CPython will
normally intern strings and thus make the test safe, value identity is
what should be used here.
author | Dan Villiom Podlaski Christiansen <danchr@gmail.com> |
---|---|
date | Tue, 16 Nov 2010 21:35:58 +0100 |
parents | 417f3c27983b |
children | e98bf6948092 |
files | mercurial/httprepo.py |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/httprepo.py Mon Nov 15 17:04:55 2010 -0600 +++ b/mercurial/httprepo.py Tue Nov 16 21:35:58 2010 +0100 @@ -68,7 +68,7 @@ raise util.Abort(_('operation not supported over http')) def _callstream(self, cmd, **args): - if cmd is 'pushkey': + if cmd == 'pushkey': args['data'] = '' data = args.pop('data', None) headers = args.pop('headers', {})