app/django/utils/thread_support.py
author Chen Lunpeng <forever.clp@gmail.com>
Fri, 17 Oct 2008 02:43:39 +0000
changeset 366 0b8700836d4f
parent 323 ff1a9aa48cfd
permissions -rw-r--r--
Fixed not working after click the "List Site Sponsors" in site menu bar. due to wrongly imported modules. Patch by: Chen Lunpeng Review by: to-be-reviewed

"""
Code used in a couple of places to work with the current thread's environment.
Current users include i18n and request prefix handling.
"""

try:
    import threading
    currentThread = threading.currentThread
except ImportError:
    def currentThread():
        return "no threading"