@effected/jsonl 0.15.2 → 0.15.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Journal.js +2 -3
- package/package.json +1 -1
- package/tsdoc-metadata.json +1 -1
package/Journal.js
CHANGED
|
@@ -42,12 +42,11 @@ var Journal = class {
|
|
|
42
42
|
*/
|
|
43
43
|
static Service() {
|
|
44
44
|
return (id, options) => {
|
|
45
|
-
const make = (config) => Effect.map(makeEngine(id, options.events, config), (engine) => engine.journal);
|
|
46
45
|
const config = Effect.isEffect(options.config) ? options.config : Effect.succeed(options.config);
|
|
47
46
|
class JournalService extends Context.Service()(id) {
|
|
48
47
|
static events = options.events;
|
|
49
|
-
static make =
|
|
50
|
-
static layer = Layer.effect(JournalService, Effect.flatMap(config, make));
|
|
48
|
+
static make = (config) => Effect.map(makeEngine(id, options.events, config), (engine) => engine.journal);
|
|
49
|
+
static layer = Layer.effect(JournalService, Effect.flatMap(config, (resolved) => JournalService.make(resolved)));
|
|
51
50
|
}
|
|
52
51
|
return JournalService;
|
|
53
52
|
};
|
package/package.json
CHANGED