--
You received this message because you are subscribed to the Google Groups "General Open edX discussion" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/edx-code/028619e9-5c25-4c00-a6c2-84f3e650e071%40googlegroups.com.
def in_preview_mode(): """ Returns whether the user is in preview mode or not. """ hostname = get_current_request_hostname() preview_lms_base = settings.FEATURES.get('PREVIEW_LMS_BASE', None) return bool(preview_lms_base and hostname and hostname.split(':')[0] == preview_lms_base.split(':')[0])
Turns out my PREVIEW_LMS_BASE was set with the same value as my LMS_BASE.
--
You received this message because you are subscribed to a topic in the Google Groups "General Open edX discussion" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/edx-code/A3DFCFC1-F017-4E8A-9CAC-544936E1A749%40edx.org.
To view this discussion on the web visit https://groups.google.com/d/msgid/edx-code/CAMfPbcZDXmL2eOJh_LuAJJfZnNgph2s-XOo4QjF93tJAXXSemg%40mail.gmail.com.
Robert Raposa
edX | Software Architect | rra...@edx.org
141 Portland Street, 9th floor
Cambridge, MA 02139
http://www.edx.orgThis e-mail (and any attachments), is confidential and may be privileged. It may be read, copied and used only by the intended recipients. Unauthorised access to this e-mail (or attachments) and disclosure or copying of its contents or any action taken in reliance on it is unlawful. Unintended recipients must notify the sender immediately by e-mail or phone and delete it from their system without making any copies or disclosing it to a third person. TeachEdison Solutions Private Limited reserves the right to store, monitor and review the content of all messages sent to or from this email address.
--
You received this message because you are subscribed to a topic in the Google Groups "General Open edX discussion" group.
To view this discussion on the web visit https://groups.google.com/d/msgid/edx-code/e53f2a5b-ad23-47f9-b75c-a7bfb9b8dab0%40googlegroups.com.