Removed document node error throw and cleaned activate-foundation.js