angularjs - Filter works but throws error anyway -


i'm filtering list based on user logged in. shows exact results in console still error:

error: [filter:notarray] expected array received: {} 

angular:

<div ng-repeat="q in questions | filter: {fields: {user: user.current}}">  <!-- --> </div> 

declaration of user.current

    $scope.user.current = fhauth.getcurrentuser().userid; 

each object in question array has array of fields;

fields[    {      'questionid': 1,     'user' : 'person1'    } ], fields[    {      'questionid': 2,     'user' : 'person2'    } ] 

edit screenshot array:

enter image description here


Comments

Popular posts from this blog

sublimetext3 - what keyboard shortcut is to comment/uncomment for this script tag in sublime -

java - No use of nillable="0" in SOAP Webservice -

ubuntu - Laravel 5.2 quickstart guide gives Not Found Error -