[IMP] README, :fields: -> :only: in demo:fields::

This commit is contained in:
Xavier Morel
2015-07-10 10:13:24 +02:00
parent 1577f53246
commit 5b2942ad58
2 changed files with 89 additions and 8 deletions
+2 -2
View File
@@ -29,7 +29,7 @@ class Fields(Directive):
required_arguments = 1
option_spec = {
'view': directives.unchanged,
'fields': directives.unchanged,
'only': directives.unchanged,
}
def __init__(self, name, arguments, options, content, lineno,
content_offset, block_text, state, state_machine):
@@ -50,7 +50,7 @@ class Fields(Directive):
return [self.state_machine.reporter.warning(
"Could not find any field related to the action [%s]" % self.arguments[0]
)]
whitelist = set(filter(None, self.options.get('fields', '').split(',')))
whitelist = set(self.options.get('only', '').split(''))
return [nodes.field_list('', *(
nodes.field('',
nodes.field_name(text=v['string'] or k),