plans: Make usable in the development environment for testing.

This commit is contained in:
Tim Abbott
2019-07-22 17:33:45 -07:00
parent 8c55e27d1e
commit 47d80977ac
4 changed files with 18 additions and 9 deletions

View File

@@ -321,7 +321,7 @@ def plans_view(request: HttpRequest) -> HttpResponse:
realm_plan_type = 0
if realm is not None:
realm_plan_type = realm.plan_type
if realm.plan_type == Realm.SELF_HOSTED:
if realm.plan_type == Realm.SELF_HOSTED and settings.PRODUCTION:
return HttpResponseRedirect('https://zulipchat.com/plans')
if not request.user.is_authenticated():
return redirect_to_login(next="plans")