Fixed/patched the UpdateCacheMiddleware so that it works even when settings.DEBUG == False.

--HG--
branch : dev
Getting Travis CI to test against postgis-enabled postgres.

--HG--
branch : dev