Show More
@@ -151,8 +151,8 b' class Alias(object):' | |||||
151 | raise InvalidAliasError("An alias command must be a string, " |
|
151 | raise InvalidAliasError("An alias command must be a string, " | |
152 | "got: %r" % self.cmd) |
|
152 | "got: %r" % self.cmd) | |
153 |
|
153 | |||
154 | nargs = self.cmd.count('%s') |
|
154 | nargs = self.cmd.count('%s') - self.cmd.count('%%s') | |
155 |
|
155 | |||
156 | if (nargs > 0) and (self.cmd.find('%l') >= 0): |
|
156 | if (nargs > 0) and (self.cmd.find('%l') >= 0): | |
157 | raise InvalidAliasError('The %s and %l specifiers are mutually ' |
|
157 | raise InvalidAliasError('The %s and %l specifiers are mutually ' | |
158 | 'exclusive in alias definitions.') |
|
158 | 'exclusive in alias definitions.') |
General Comments 0
You need to be logged in to leave comments.
Login now