Add controller logic and delete old file