You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by rn...@apache.org on 2019/02/25 21:54:36 UTC
[couchdb-ken] 02/06: Fix compilation errors and use of macro
This is an automated email from the ASF dual-hosted git repository.
rnewson pushed a commit to branch else
in repository https://gitbox.apache.org/repos/asf/couchdb-ken.git
commit 50682f928e6d2b371415c53cca2180c14bdd3408
Author: Robert Newson <rn...@apache.org>
AuthorDate: Mon Feb 25 18:37:48 2019 +0000
Fix compilation errors and use of macro
A bit of confusion with HAS_ and HAVE_ led to me not noticing that the
dreyfus/hastings bits didn't compile.
---
src/ken_server.erl | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/ken_server.erl b/src/ken_server.erl
index 25da5ac..91f18c1 100644
--- a/src/ken_server.erl
+++ b/src/ken_server.erl
@@ -309,15 +309,15 @@ update_ddoc_indexes(Name, #doc{}=Doc, State) ->
false ->
ok
end,
- SearchUpdated = search_updated(Doc, Seq, State),
- STUpdated = st_updated(Doc, Seq, State),
+ SearchUpdated = search_updated(Name, Doc, Seq, State),
+ STUpdated = st_updated(Name, Doc, Seq, State),
case {ViewUpdated, SearchUpdated, STUpdated} of
{ok, ok, ok} -> ok;
_ -> resubmit
end.
--ifdef(HAS_DREYFUS).
-search_updated(Doc, Seq, State) ->
+-ifdef(HAVE_DREYFUS).
+search_updated(Name, Doc, Seq, State) ->
case should_update(Doc, <<"indexes">>) of true ->
try dreyfus_index:design_doc_to_indexes(Doc) of
SIndexes -> update_ddoc_search_indexes(Name, SIndexes, Seq, State)
@@ -332,8 +332,8 @@ search_updated(_Doc, _Seq, _State) ->
ok.
-endif.
--ifdef(HAS_HASTINGS).
-st_updated(Doc, Seq, State) ->
+-ifdef(HAVE_HASTINGS).
+st_updated(Name, Doc, Seq, State) ->
case should_update(Doc, <<"st_indexes">>) of true ->
try
hastings_index:design_doc_to_indexes(Doc) of