Cleaned some code, sort view is now working but needs cleaning up.