fixed url_redirects when USE_I18N=True, but no i18n_patterns is used

Currently, the code checks if ``USE_I18N`` is set to ``False``. If it's ``True``, a language prefix is added.

There are cases where one doesn't need language prefixes (only a single active language), but still wants ``USE_I18N = True`` (e.g. to make use of the django translation framework).

This PR includes a copy of django's ``LocaleMiddleware.is_language_prefix_patterns_used()`` to do a proper check if a language prefix is needed or not.