Cleans up old code