You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by be...@apache.org on 2014/07/13 14:29:42 UTC
[2/7] couch-mrview commit: updated refs/heads/1994-merge-rcouch to
4e0f295
make sure we can pass a db name to couch_mrview:trigger_update/{2,3}
Project: http://git-wip-us.apache.org/repos/asf/couchdb-couch-mrview/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-couch-mrview/commit/33d4a0f4
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-couch-mrview/tree/33d4a0f4
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-couch-mrview/diff/33d4a0f4
Branch: refs/heads/1994-merge-rcouch
Commit: 33d4a0f4742129123ca0a35dcf6a88bd87e5a816
Parents: 6c96010
Author: benoitc <bc...@gmail.com>
Authored: Tue Mar 4 11:12:35 2014 +0100
Committer: benoitc <bc...@gmail.com>
Committed: Tue Mar 4 11:12:35 2014 +0100
----------------------------------------------------------------------
src/couch_mrview.erl | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb-couch-mrview/blob/33d4a0f4/src/couch_mrview.erl
----------------------------------------------------------------------
diff --git a/src/couch_mrview.erl b/src/couch_mrview.erl
index 9f6b70d..6112cbd 100644
--- a/src/couch_mrview.erl
+++ b/src/couch_mrview.erl
@@ -192,10 +192,15 @@ refresh(Db, DDoc) ->
{error, Error}
end.
+trigger_update(#db{name=DbName}, DDoc) ->
+ trigger_update(DbName, DDoc);
trigger_update(Db, DDoc) ->
- trigger_update(Db, DDoc, couch_db:get_update_seq(Db)).
+ UpdateSeq = couch_util:with_db(Db, fun(WDb) ->
+ couch_db:get_update_seq(WDb)
+ end),
+ trigger_update(Db, DDoc, UpdateSeq).
trigger_update(Db, DDoc, UpdateSeq) ->
{ok, Pid} = couch_index_server:get_index(couch_mrview_index, Db, DDoc),