You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by da...@apache.org on 2019/07/23 21:54:59 UTC
[couchdb] 14/31: fixup! Expose the is_replicator_db and is_user_db
logic
This is an automated email from the ASF dual-hosted git repository.
davisp pushed a commit to branch prototype/views
in repository https://gitbox.apache.org/repos/asf/couchdb.git
commit 047ccabe3b452c5777aec0f2376681c33ba92e81
Author: Paul J. Davis <pa...@gmail.com>
AuthorDate: Thu Jul 18 15:04:37 2019 -0500
fixup! Expose the is_replicator_db and is_user_db logic
---
src/fabric/src/fabric2_db.erl | 2 +-
src/fabric/src/fabric2_util.erl | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/fabric/src/fabric2_db.erl b/src/fabric/src/fabric2_db.erl
index a89b098..c926da9 100644
--- a/src/fabric/src/fabric2_db.erl
+++ b/src/fabric/src/fabric2_db.erl
@@ -385,7 +385,7 @@ is_replicator_db(#{name := DbName}) ->
is_replicator_db(DbName);
is_replicator_db(DbName) when is_binary(DbName) ->
- fabric2_util:dbname_ends_with(Db, <<"_replicator">>).
+ fabric2_util:dbname_ends_with(DbName, <<"_replicator">>).
is_users_db(#{name := DbName}) ->
diff --git a/src/fabric/src/fabric2_util.erl b/src/fabric/src/fabric2_util.erl
index 1921bca..2b8e49e 100644
--- a/src/fabric/src/fabric2_util.erl
+++ b/src/fabric/src/fabric2_util.erl
@@ -125,7 +125,7 @@ validate_json_list_of_strings(Member, Props) ->
dbname_ends_with(#{} = Db, Suffix) ->
- dbname_ends_with(fabric2_db:name(Db), Suffix).
+ dbname_ends_with(fabric2_db:name(Db), Suffix);
dbname_ends_with(DbName, Suffix) when is_binary(DbName), is_binary(Suffix) ->
Suffix == filename:basename(DbName).