made magic lamp throw its own argument error instead of the global to avoid confusion