-
Notifications
You must be signed in to change notification settings - Fork 105
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Prevent StreamingPayment uninstallation if pending streams remain #1251
base: develop
Are you sure you want to change the base?
Conversation
1a54bad
to
a17d2b7
Compare
f75fde4
to
d63d67b
Compare
a17d2b7
to
9fddd41
Compare
53b7bbf
to
58d4d6e
Compare
fc1cdaa
to
a78f8c2
Compare
1929430
to
78ab0ee
Compare
c0ee585
to
5a5ae87
Compare
78ab0ee
to
273ee11
Compare
5a5ae87
to
89fe76c
Compare
273ee11
to
943a097
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a lot of new code just to implement an uninstall check, but so it goes I guess
@@ -184,6 +191,10 @@ contract StreamingPayments is ColonyExtensionMeta { | |||
0 | |||
); | |||
|
|||
if (getAmountClaimableLifetime(numStreamingPayments) > 0) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this check necessary? Why would we allow a streaming payment to be created which was worth nothing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We already allowed it, so I had to accommodate it. The alternative would be adding a check instead of this, so it feels like much of a wash to me. In addition, there's nothing stopping you editing a stream you create down to being worth nothing, so preventing creation feels quite arbitrary?
943a097
to
d168916
Compare
d168916
to
295f2e2
Compare
295f2e2
to
de82deb
Compare
The main feature here is to prevent uninstallation of the extension in the event that there are some streaming payments unclaimed. It also: