Skip to content

Commit af89520

Browse files
committed
ensure that context creation is only logged when it's actually happening
1 parent c441b76 commit af89520

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/main/java/org/wiremock/extensions/state/internal/ContextManager.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,10 @@ public ContextManager(Store<String, Object> store, TransactionManager transactio
3838
}
3939

4040
private static Supplier<Context> createNewContext(String contextName) {
41-
logger().info(contextName, "created");
42-
return () -> new Context(contextName);
41+
return () -> {
42+
logger().info(contextName, "created");
43+
return new Context(contextName);
44+
};
4345
}
4446

4547
/**

0 commit comments

Comments
 (0)