Skip to content

Commit 100118d

Browse files
committed
convertType
1 parent 586149e commit 100118d

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

playwright/src/main/java/com/microsoft/playwright/impl/BrowserTypeImpl.java

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -203,15 +203,7 @@ private BrowserContextImpl launchPersistentContextImpl(Path userDataDir, LaunchP
203203
if (options.baseURL != null) {
204204
context.setBaseUrl(options.baseURL);
205205
}
206-
207-
Browser.NewContextOptions harOptions = new Browser.NewContextOptions();
208-
harOptions.recordHarContent = options.recordHarContent;
209-
harOptions.recordHarMode = options.recordHarMode;
210-
harOptions.recordHarOmitContent = options.recordHarOmitContent;
211-
harOptions.recordHarPath = options.recordHarPath;
212-
harOptions.recordHarUrlFilter = options.recordHarUrlFilter;
213-
context.initializeHarFromOptions(harOptions);
214-
206+
context.initializeHarFromOptions(convertType(options, Browser.NewContextOptions.class));
215207
context.tracing().setTracesDir(options.tracesDir);
216208
return context;
217209
}

0 commit comments

Comments
 (0)