-
Notifications
You must be signed in to change notification settings - Fork 510
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
Improve calling addListener #4244
Conversation
@@ -27,12 +27,12 @@ import app.cash.sqldelight.db.SqlDriver | |||
@Suppress("FunctionName") // Emulating a constructor. | |||
fun <RowType : Any> Query( | |||
identifier: Int, | |||
queryKeys: Array<String>, | |||
vararg queryKeys: String, |
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.
Do we want to change this api too? This aligns with the addListener
methods, but requires a lot of changes due to required named parameters.
Given that we've now pushed out a release candidate, the intent is to keep the API frozen. This is a breaking change so I think the ship has sailed on this for 2.0. Can this be added as an extension method instead? |
We don’t accept any breaking changes? We still do have some open issues marked with milestone 2.0 which will break the current api. |
It works, see #4244. fun test(vararg test: String, foo: Foo) |
Ah my bad, I named the parameter |
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.
yolo
Fixes #4237
I also changed
queryKeys: Array<String>
tovararg queryKeys: String
, because I think, this api is nicer as developer.