Code Restructure