let persister flow nullables to understand absense. (#30)

This is possibly temporary until we get a StoreResponse but may still keep
it as we wouldn't want to force everything to support StoreResponse
This commit is contained in:
Yigit Boyar 2019-08-15 23:24:21 +03:00 committed by GitHub
parent d1ac07d8d0
commit 92022be61a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -51,7 +51,7 @@ fun <Key, Output> PipelineStore<Key, Output>.withCache(
@FlowPreview
fun <Key, OldOutput, NewOutput> PipelineStore<Key, OldOutput>.withPersister(
reader: (Key) -> Flow<NewOutput>,
reader: (Key) -> Flow<NewOutput?>,
writer: suspend (Key, OldOutput) -> Unit,
delete: (suspend (Key) -> Unit)? = null
): PipelineStore<Key, NewOutput> {