Skip to content

Commit

Permalink
cs
Browse files Browse the repository at this point in the history
  • Loading branch information
dg committed Jan 16, 2025
1 parent 6f74d2c commit 75efd23
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Forms/Controls/DateTimeControl.php
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public function formatHtmlValue(\DateTimeInterface|string|int $value): string
return $this->normalizeValue($value)->format(match ($this->type) {
self::TypeDate => 'Y-m-d',
self::TypeTime => $this->withSeconds ? 'H:i:s' : 'H:i',
self::TypeDateTime => $this->withSeconds ? 'Y-m-d\\TH:i:s' : 'Y-m-d\\TH:i',
self::TypeDateTime => $this->withSeconds ? 'Y-m-d\TH:i:s' : 'Y-m-d\TH:i',
});
}

Expand Down
4 changes: 2 additions & 2 deletions tests/Forms/Controls.UploadControl.loadData.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ $_FILES = [
'container' => [
'name' => ['avatar' => "invalid\xAA\xAA\xAAutf"],
'type' => ['avatar' => 'text/plain'],
'tmp_name' => ['avatar' => 'C:\\PHP\\temp\\php1D5C.tmp'],
'tmp_name' => ['avatar' => 'C:\PHP\temp\php1D5C.tmp'],
'error' => ['avatar' => 0],
'size' => ['avatar' => 3013],
],
Expand Down Expand Up @@ -91,7 +91,7 @@ test('container', function () {
'name' => '',
'type' => '',
'size' => 3013,
'tmp_name' => 'C:\\PHP\\temp\\php1D5C.tmp',
'tmp_name' => 'C:\PHP\temp\php1D5C.tmp',
'error' => 0,
]), $input->getValue());
Assert::true($input->isFilled());
Expand Down
2 changes: 1 addition & 1 deletion tests/Forms/Helpers.exportRules.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,6 @@ test('addFilter', function () {
$input->setRequired(false);
$input->addRule(Form::Email);
Assert::same([
['op' => ':pattern', 'msg' => 'match pattern', 'arg' => '\\d+'],
['op' => ':pattern', 'msg' => 'match pattern', 'arg' => '\d+'],
], Helpers::exportRules($input->getRules()));
});

0 comments on commit 75efd23

Please sign in to comment.