Update index.php

1.7　Bug fixes

ViewModel is executed twice

Return value of RESTController is for array