Restructure logic
Update modules