summaryrefslogtreecommitdiff
path: root/examples/statemachine/libraryBookDemo.py
diff options
context:
space:
mode:
Diffstat (limited to 'examples/statemachine/libraryBookDemo.py')
-rw-r--r--examples/statemachine/libraryBookDemo.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/statemachine/libraryBookDemo.py b/examples/statemachine/libraryBookDemo.py
index 84108e5..2e60eac 100644
--- a/examples/statemachine/libraryBookDemo.py
+++ b/examples/statemachine/libraryBookDemo.py
@@ -19,7 +19,7 @@ class Book:
return attr
def __str__(self):
- return "{}: {}".format(self.__class__.__name__, self._state)
+ return "{0}: {1}".format(self.__class__.__name__, self._state)
class RestrictedBook(Book):
@@ -35,7 +35,7 @@ class RestrictedBook(Book):
if user in self._authorized_users:
self._state = self._state.checkout()
else:
- raise Exception("{} could not check out restricted book".format((user, "anonymous")[user is None]))
+ raise Exception("{0} could not check out restricted book".format((user, "anonymous")[user is None]))
def run_demo():