(ddocName string)
| 84 | } |
| 85 | |
| 86 | func (db *Database) GetDesignDoc(ddocName string) (ddoc sgbucket.DesignDoc, err error) { |
| 87 | if err = db.checkDDocAccess(ddocName); err != nil { |
| 88 | return ddoc, err |
| 89 | } |
| 90 | vs, err := getViewStoreForDefaultCollection(db.DatabaseContext) |
| 91 | if err != nil { |
| 92 | return ddoc, err |
| 93 | } |
| 94 | return vs.GetDDoc(ddocName) |
| 95 | } |
| 96 | |
| 97 | func (db *Database) PutDesignDoc(ctx context.Context, ddocName string, ddoc sgbucket.DesignDoc) (err error) { |
| 98 | wrap := true |