Restructured code for later features