Fix contributor list, add kredits service tests #115

Merged
raucao merged 7 commits from bugfix/114-contributor_list into master 2019-05-08 10:35:01 +00:00
raucao commented 2019-05-06 16:27:19 +00:00 (Migrated from github.com)

closes #114

closes #114
bumi (Migrated from github.com) approved these changes 2019-05-06 18:25:58 +00:00
bumi (Migrated from github.com) left a comment

LGTM!

LGTM!
galfert (Migrated from github.com) approved these changes 2019-05-08 09:09:35 +00:00
galfert (Migrated from github.com) left a comment

Just left one comment. The rest looks good to me.

Just left one comment. The rest looks good to me.
@@ -45,19 +45,34 @@ export default Service.extend({
});
}),
galfert (Migrated from github.com) commented 2019-05-08 09:05:51 +00:00

I think you might want to change the dependency, so the computed property updates when the vetoed status of any of the contributions changes.

   kreditsByContributor: computed('contributionsUnconfirmed.@each.vetoed', 'contributors', function() {
I think you might want to change the dependency, so the computed property updates when the `vetoed` status of any of the contributions changes. ```suggestion kreditsByContributor: computed('contributionsUnconfirmed.@each.vetoed', 'contributors', function() { ```
raucao (Migrated from github.com) reviewed 2019-05-08 09:45:19 +00:00
@@ -45,19 +45,34 @@ export default Service.extend({
});
}),
raucao (Migrated from github.com) commented 2019-05-08 09:45:19 +00:00

Cool. Will that still account for new and deleted objects in the collection, and changes of other properties?

Cool. Will that still account for new and deleted objects in the collection, and changes of other properties?
galfert (Migrated from github.com) reviewed 2019-05-08 10:19:31 +00:00
@@ -45,19 +45,34 @@ export default Service.extend({
});
}),
galfert (Migrated from github.com) commented 2019-05-08 10:19:30 +00:00

Yes, it will also update when the array itself changes (e.g. elements added or removed). If you want to add additional properties as dependencies, you would add them like this contributionsUnconfirmed.@each.{vetoed,otherProperty}.

Yes, it will also update when the array itself changes (e.g. elements added or removed). If you want to add additional properties as dependencies, you would add them like this `contributionsUnconfirmed.@each.{vetoed,otherProperty}`.
Sign in to join this conversation.