File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -129,8 +129,11 @@ export class StorageUtils {
129129 await this . page . locator ( '#ftppass' ) . fill ( BACKWPUP_INFOS . ftp . password ) ;
130130 await this . page . locator ( '#ftphostport' ) . fill ( BACKWPUP_INFOS . ftp . port ?? '21' ) ;
131131 // Checkboxes
132- await this . page . locator ( '#ftpssl' ) . setChecked ( BACKWPUP_INFOS . ftp . ssl , { force : true } ) ;
132+ // Only set SSL checkbox if the SSL option checkbox element exists and is visible
133+ const sslCheckboxVisible = await this . page . locator ( '#ftpssl' ) . isVisible ( ) . catch ( ( ) => false ) ;
134+ if ( sslCheckboxVisible ) {
133135 await this . page . locator ( '#ftppasv' ) . setChecked ( BACKWPUP_INFOS . ftp . passiveMode , { force : true } ) ;
136+ }
134137 const timestamp = Date . now ( ) ;
135138 const directoryName = getFolderNameFromHost ( ) ;
136139 // Changing the directory name to prevent old backups to appear and affect the test
You can’t perform that action at this time.
0 commit comments