Used stored design document if auto_update_design_doc is disabled
This commit is contained in:
parent
f2c16144b0
commit
39c60d77d2
2 changed files with 60 additions and 27 deletions
|
@ -7,7 +7,11 @@ module CouchRest
|
|||
module ClassMethods
|
||||
|
||||
def design_doc
|
||||
@design_doc ||= ::CouchRest::Design.new(default_design_doc)
|
||||
@design_doc ||= if auto_update_design_doc
|
||||
::CouchRest::Design.new(default_design_doc)
|
||||
else
|
||||
stored_design_doc
|
||||
end
|
||||
end
|
||||
|
||||
def design_doc_id
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue