Update frontend.js

fix typo in method call