Views cleanup part 1.
Refactor renaming objects and moving them out of views.py
Tweak to URL file type matching.