summaryrefslogtreecommitdiffstats
path: root/hyperkitty/views/thread.py
diff options
context:
space:
mode:
Diffstat (limited to 'hyperkitty/views/thread.py')
-rw-r--r--hyperkitty/views/thread.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/hyperkitty/views/thread.py b/hyperkitty/views/thread.py
index f8820c9..fd0d466 100644
--- a/hyperkitty/views/thread.py
+++ b/hyperkitty/views/thread.py
@@ -7,13 +7,14 @@ from django.core.paginator import Paginator, EmptyPage, PageNotAnInteger, Invali
from django.contrib.auth.decorators import (login_required,
permission_required,
user_passes_test)
+from kittystore import get_store
from hyperkitty.models import Rating, Tag
#from hyperkitty.lib.mockup import *
from forms import *
from hyperkitty.utils import log
+from hyperkitty.lib import get_months
-from hyperkitty.lib import ThreadSafeStorePool, get_months
def thread_index (request, mlist_fqdn, threadid):
@@ -22,8 +23,8 @@ def thread_index (request, mlist_fqdn, threadid):
search_form = SearchForm(auto_id=False)
t = loader.get_template('thread.html')
- STORE = ThreadSafeStorePool().get()
- threads = STORE.get_messages_in_thread(mlist_fqdn, threadid)
+ store = get_store(settings.KITTYSTORE_URL)
+ threads = store.get_messages_in_thread(mlist_fqdn, threadid)
#prev_thread = mongo.get_thread_name(list_name, int(threadid) - 1)
prev_thread = []
if len(prev_thread) > 30:
@@ -65,7 +66,7 @@ def thread_index (request, mlist_fqdn, threadid):
participants[message.sender_name] = {'email': message.sender_email}
cnt = cnt + 1
- archives_length = get_months(STORE, mlist_fqdn)
+ archives_length = get_months(store, mlist_fqdn)
from_url = '/thread/%s/%s/' % (mlist_fqdn, threadid)
tag_form = AddTagForm(initial={'from_url' : from_url})