Skip to content

Commit

Permalink
PES-2539: width validation update (#709)
Browse files Browse the repository at this point in the history
  • Loading branch information
zemekoule authored Jan 21, 2025
2 parents e85795c + 69f8ab8 commit 4a28628
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Packetery/Module/Options/Page.php
Original file line number Diff line number Diff line change
Expand Up @@ -550,7 +550,7 @@ public function create_form(): Form {

$container->addText( 'default_width', __( 'Width', 'packeta' ) )
->addConditionOn( $form[ self::FORM_FIELDS_CONTAINER ]['default_dimensions_enabled'], Form::EQUAL, true )
->setRequired( 'Width is required when default dimensions are enabled.' )
->setRequired()
->addConditionOn( $form[ self::FORM_FIELDS_CONTAINER ]['dimensions_unit'], Form::EQUAL, $this->optionsProvider::DEFAULT_DIMENSIONS_UNIT_MM )
->addRule( Form::INTEGER, __( 'Provide a full number!', 'packeta' ) )
->addRule( Form::MIN, 'Value must be greater than 0', 1 )
Expand Down

0 comments on commit 4a28628

Please sign in to comment.