Error 500

Call to a member function getData() on array