Moved stuff around. Added new refresh view logic