Skip to content

Collections are zero-length inside $then #154

@adammw

Description

@adammw

When accessing a collection from inside $then, the array length of the collection is zero regardless of the data.

$scope.users = User.$search({ page: $scope.page }).$then(function(users) {
  console.log(users.length);
  users.forEach(function(user) {
    console.log(user);
  });
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions