Update staples.js

Formally requires the mag namespace to run