Update spa.js

bug fixed
Merge pull request #11 from pasu777/patch-1

Update spa.js