X-Git-Url: https://git.mdrn.pl/wolnelektury.git/blobdiff_plain/ca7bffa0f660afefb98d37ac002b9652e1c858e5..281a6f613c78ffd1fa81951db829a5551fd2e42d:/apps/search/custom.py?ds=sidebyside diff --git a/apps/search/custom.py b/apps/search/custom.py index 33ce47d32..6cb18fd24 100644 --- a/apps/search/custom.py +++ b/apps/search/custom.py @@ -85,9 +85,9 @@ class CustomSolrInterface(sunburnt.SolrInterface): def __init__(self, url, schemadoc=None, http_connection=None, mode='', retry_timeout=-1, max_length_get_url=sunburnt.MAX_LENGTH_GET_URL): self.conn = CustomSolrConnection(url, http_connection, retry_timeout, max_length_get_url) self.schemadoc = schemadoc - if mode == 'r': + if 'w' not in mode: self.writeable = False - elif mode == 'w': + elif 'r' not in mode: self.readable = False self.init_schema()