Skip to content

Commit 2a3ab52

Browse files
committed
Merge branch 'refactor-curler'
2 parents e5dc75b + 2facdd3 commit 2a3ab52

File tree

83 files changed

+2337
-518
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

83 files changed

+2337
-518
lines changed

.phive/phars.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="UTF-8"?>
22
<phive xmlns="https://phar.io/phive">
3-
<phar name="lkrms/pretty-php" version="^0.4.48" installed="0.4.56" location="./tools/pretty-php" copy="true"/>
4-
<phar name="php-cs-fixer" version="^3.46.0" installed="3.52.1" location="./tools/php-cs-fixer" copy="true"/>
3+
<phar name="lkrms/pretty-php" version="^0.4.48" installed="0.4.60" location="./tools/pretty-php" copy="true"/>
4+
<phar name="php-cs-fixer" version="^3.46.0" installed="3.53.0" location="./tools/php-cs-fixer" copy="true"/>
55
<phar name="salient-labs/php-changelog" version="^1.0.0" installed="1.0.4" location="./tools/changelog" copy="true"/>
66
</phive>

.php-cs-fixer.dist.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@
3939
'template',
4040
'extends',
4141
'implements',
42+
'phpstan-require-extends',
43+
'phpstan-require-implements',
4244
'readonly',
4345
'var',
4446
'param',
@@ -52,6 +54,7 @@
5254
['requires', 'dataProvider', 'backupGlobals'],
5355
['template', 'template-covariant'],
5456
['extends', 'implements'],
57+
['phpstan-require-extends', 'phpstan-require-implements'],
5558
['readonly', 'var', 'phpstan-var', 'param', 'param-out', 'phpstan-param', 'return', 'phpstan-return', 'throws', 'phpstan-assert*', 'phpstan-ignore-next-line'],
5659
['phpstan-*'],
5760
]],

.vscode/php.code-snippets

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"body": [
66
"<?php declare(strict_types=1);",
77
"",
8-
"namespace ${TM_DIRECTORY/^.*\\\\/src\\\\/(Toolkit|(Sli|PHPStan))|^.*\\\\/(tests\\\\/(?:unit|fixtures|3rdparty)\\\\/(Toolkit|(Sli|PHPStan)))|\\\\/([a-zA-Z0-9]+)/${1:+Salient}${2:+\\\\}$2${4:+Salient}${3:+\\\\Tests}${5:+\\\\}$5${6:+\\\\}$6/g};",
8+
"namespace ${TM_DIRECTORY/^.*\\\\/src\\\\/(Toolkit|(Sli))|^.*\\\\/(tests\\\\/(?:unit|fixtures|3rdparty)\\\\/(Toolkit|(Sli)))|\\\\/([a-zA-Z0-9]+)/${1:+Salient}${2:+\\\\}$2${4:+Salient}${3:+\\\\Tests}${5:+\\\\}$5${6:+\\\\}$6/g};",
99
"",
1010
"${RELATIVE_FILEPATH/(?:.*(?:(\\\\/Contract\\\\/.*|Interface\\.php$)|(\\\\/Concern\\\\/.*|Trait\\.php$))|(^(?:.(?!\\\\/(?:Contract|Concern)\\\\/|(?:Interface|Trait)\\.php$))*$))/${1:+interface}${2:+trait}${3:+class}/} ${TM_FILENAME_BASE/[^a-zA-Z0-9]+//g} {",
1111
" $0",
@@ -17,7 +17,7 @@
1717
"scope": "php",
1818
"prefix": "namespace",
1919
"body": [
20-
"namespace ${TM_DIRECTORY/^.*\\\\/src\\\\/(Toolkit|(Sli|PHPStan))|^.*\\\\/(tests\\\\/(?:unit|fixtures|3rdparty)\\\\/(Toolkit|(Sli|PHPStan)))|\\\\/([a-zA-Z0-9]+)/${1:+Salient}${2:+\\\\}$2${4:+Salient}${3:+\\\\Tests}${5:+\\\\}$5${6:+\\\\}$6/g};"
20+
"namespace ${TM_DIRECTORY/^.*\\\\/src\\\\/(Toolkit|(Sli))|^.*\\\\/(tests\\\\/(?:unit|fixtures|3rdparty)\\\\/(Toolkit|(Sli)))|\\\\/([a-zA-Z0-9]+)/${1:+Salient}${2:+\\\\}$2${4:+Salient}${3:+\\\\Tests}${5:+\\\\}$5${6:+\\\\}$6/g};"
2121
]
2222
}
2323
}

composer.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,12 +49,13 @@
4949
"sebastian/diff": "^4 || ^5"
5050
},
5151
"provide": {
52-
"psr/event-dispatcher-implementation": "^1"
52+
"psr/event-dispatcher-implementation": "^1",
53+
"psr/http-factory-implementation": "^1",
54+
"psr/http-message-implementation": "^1.1 || ^2"
5355
},
5456
"autoload": {
5557
"psr-4": {
56-
"Salient\\": "src/Toolkit/",
57-
"Salient\\PHPStan\\": "src/PHPStan/"
58+
"Salient\\": "src/Toolkit/"
5859
},
5960
"classmap": [
6061
"stubs/"
@@ -66,7 +67,6 @@
6667
"autoload-dev": {
6768
"psr-4": {
6869
"Salient\\Sli\\": "src/Sli/",
69-
"Salient\\Tests\\PHPStan\\": "tests/unit/PHPStan/",
7070
"Salient\\Tests\\": [
7171
"tests/unit/Toolkit/",
7272
"tests/fixtures/Toolkit/",

phpstan-baseline-7.4.neon

Lines changed: 0 additions & 35 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

phpstan-baseline-8.3.neon

Lines changed: 0 additions & 35 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

phpstan.extension.neon

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
services:
22
-
3-
class: Salient\PHPStan\Core\Utility\Str\MethodReturnTypeExtension
3+
class: Salient\PHPStan\Type\Core\GetCoalesceMethodReturnTypeExtension
44
tags:
55
- phpstan.broker.dynamicStaticMethodReturnTypeExtension
66

77
-
8-
class: Salient\PHPStan\Core\Utility\Get\MethodReturnTypeExtension
8+
class: Salient\PHPStan\Type\Core\StrCoalesceMethodReturnTypeExtension
99
tags:
1010
- phpstan.broker.dynamicStaticMethodReturnTypeExtension

src/Toolkit/Contract/Core/MimeType.php

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,21 @@
55
use Salient\Core\AbstractDictionary;
66

77
/**
8-
* Frequently-used MIME types
8+
* @api
99
*
1010
* @extends AbstractDictionary<string>
1111
*/
1212
final class MimeType extends AbstractDictionary
1313
{
14-
public const TEXT = 'text/plain';
1514
public const BINARY = 'application/octet-stream';
16-
public const WWW_FORM = 'application/x-www-form-urlencoded';
15+
public const FORM = 'application/x-www-form-urlencoded';
16+
public const FORM_MULTIPART = 'multipart/form-data';
17+
public const GZIP = 'application/gzip';
18+
public const HTML = 'text/html';
1719
public const JSON = 'application/json';
20+
public const JWT = 'application/jwt';
21+
public const TEXT = 'text/plain';
22+
public const XML = 'application/xml';
23+
public const YAML = 'application/yaml';
24+
public const ZIP = 'application/zip';
1825
}

0 commit comments

Comments
 (0)