Skip to content

[BUG] Fetcher and SourceOfTruth must now have the same type signatures #183

@chrisbanes

Description

@chrisbanes

I'm just updating to alpha06, and hit a bit of a roadblock....

The old API allowed this:

return StoreBuilder.fromNonFlow<Param, Pair<Result, ExtraInfo> { p: Param ->
    return result to extraInfoWhichPersisterNeeds
}.persister<Param, Result>(
    writer = { (result, extraInfo) ->
        // persist, using the extra info
    }
}

But now the SourceOfTruth and Fetcher need to have the same type signatures, so there's no way to pass along that extra info. Feels a little restrictive to me.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions