Skip to content
This repository

Fix for accessing extra_data #33

wants to merge 1 commit into from

1 participant

Ryan Showalter
Ryan Showalter

Hey guys,

It's currently impossible to set extra data by doing something like the following:['foo'] = 'bar'

It's because the extra_data getter property will always return an 'anonymous' dict instance if the extra_data dict is empty.

This commit should fix that problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Feb 24, 2012
Don't return an anonymous dict when accessing extra_data 455c5ad
This page is out of date. Refresh to see the latest.

Showing 1 changed file with 1 addition and 1 deletion. Show diff stats Hide diff stats

  1. 2  formwizard/storage/
2  formwizard/storage/
@@ -40,7 +40,7 @@ def _set_current_step(self, step):
40 40
     current_step = lazy_property(_get_current_step, _set_current_step)
41 41
42 42
     def _get_extra_data(self):
-        return[self.extra_data_key] or {}
+        return[self.extra_data_key]
44 44
45 45
     def _set_extra_data(self, extra_data):
46 46[self.extra_data_key] = extra_data

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.