Skip to content

Commit

Permalink
use the new style of string formatting
Browse files Browse the repository at this point in the history
- Using the % to format the strings is in the process of being
  deprecated. It's recommended that the new style (defined by
  PEP #3101[1]) be used for new code moving forward.

[1] http://docs.python.org/3.0/whatsnew/2.6.html#pep-3101
  • Loading branch information
theckman committed Jan 2, 2013
1 parent cb62702 commit bad10f9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion totp.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__ (self, confFile):
Code = unpack('>L', ShortHash)[0]
Code &= 0x7FFFFFFF
Code %= 1000000
Code = "%06d" % Code
Code = '{0:06d}'.format(Code)
self.keys.append(Code)

def authenticate(self, Code):
Expand Down

0 comments on commit bad10f9

Please sign in to comment.