Yes, it's studio. I didn't write the preview code, but afaik it lets the user define any hostname for the preview (see, dev_shared_preview.py & lms/envs/cms/dev.py); so, hardcoded search for `preview.` could fail. What to do in place of that will take more thought. (perhaps access the `settings.MITX_FEATURES['PREVIEW_LMS_BASE']` value?) Then again, perhaps the middleware should be stripping the PREVIEW_LMS_BASE once it's set the mongo db default?