summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Doc/library/optparse.rst2
1 files changed, 1 insertions, 1 deletions
diff --git a/Doc/library/optparse.rst b/Doc/library/optparse.rst
index 604ac7f..4ef2ba7 100644
--- a/Doc/library/optparse.rst
+++ b/Doc/library/optparse.rst
@@ -1511,7 +1511,7 @@ Here's an example of a callback option that takes no arguments, and simply
records that the option was seen::
def record_foo_seen(option, opt_str, value, parser):
- parser.saw_foo = True
+ parser.values.saw_foo = True
parser.add_option("--foo", action="callback", callback=record_foo_seen)