Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitaf9090d

Browse files
authored
Merge pull request#49 from saloonphp/fix/v3-fix-stubs
Fix | V3 Update Stubs
2 parents92599e3 +29b7b4d commitaf9090d

File tree

8 files changed

+9
-25
lines changed

8 files changed

+9
-25
lines changed

‎config/saloon.php‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,13 @@
2626
|--------------------------------------------------------------------------
2727
|
2828
| By default, this package will create any classes within
29-
| /app/Http/Integrations directory. If you're using
29+
|`/app/Http/Integrations` directory. If you're using
3030
| a different design approach, then your classes
3131
| may be in a different place. You can change
3232
| that location so that the saloon:list
3333
| command will still find your files
3434
|
3535
*/
36-
'integrations_path' =>'App/Http/Integrations',
36+
37+
'integrations_path' =>base_path('App/Http/Integrations'),
3738
];

‎src/Console/Commands/MakeCommand.php‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ abstract class MakeCommand extends GeneratorCommand
2626
*/
2727
protectedfunctiongetStub()
2828
{
29-
return$this->resolveStubPath('/stubs/' .$this->resolveStubName());
29+
return$this->resolveStubPath('/../../../stubs/' .$this->resolveStubName());
3030
}
3131

3232
protectedfunctionresolveStubName():string

‎src/Console/Commands/stubs/saloon.authenticator.stub‎renamed to ‎stubs/saloon.authenticator.stub‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace {{ namespace }};
44

5-
use Saloon\Contracts\PendingRequest;
5+
use Saloon\Http\PendingRequest;
66
use Saloon\Contracts\Authenticator;
77

88
class {{ class }} implements Authenticator
@@ -14,9 +14,6 @@ class {{ class }} implements Authenticator
1414

1515
/**
1616
* Apply the authentication to the request.
17-
*
18-
* @param PendingRequest $pendingRequest
19-
* @return void
2017
*/
2118
public function set(PendingRequest $pendingRequest): void
2219
{

‎src/Console/Commands/stubs/saloon.connector.stub‎renamed to ‎stubs/saloon.connector.stub‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ class {{ class }} extends Connector
1111

1212
/**
1313
* The Base URL of the API
14-
*
15-
* @return string
1614
*/
1715
public function resolveBaseUrl(): string
1816
{
@@ -21,8 +19,6 @@ class {{ class }} extends Connector
2119

2220
/**
2321
* Default headers for every request
24-
*
25-
* @return string[]
2622
*/
2723
protected function defaultHeaders(): array
2824
{
@@ -31,8 +27,6 @@ class {{ class }} extends Connector
3127

3228
/**
3329
* Default HTTP client options
34-
*
35-
* @return string[]
3630
*/
3731
protected function defaultConfig(): array
3832
{

‎src/Console/Commands/stubs/saloon.oauth-connector.stub‎renamed to ‎stubs/saloon.oauth-connector.stub‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,18 +14,14 @@ class {{ class }} extends Connector
1414

1515
/**
1616
* The Base URL of the API.
17-
*
18-
* @return string
1917
*/
2018
public function resolveBaseUrl(): string
2119
{
2220
return '';
2321
}
2422

2523
/**
26-
* Define the default OAuth2 Config.
27-
*
28-
* @return OAuthConfig
24+
* The OAuth2 configuration
2925
*/
3026
protected function defaultOauthConfig(): OAuthConfig
3127
{

‎src/Console/Commands/stubs/saloon.plugin.stub‎renamed to ‎stubs/saloon.plugin.stub‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
namespace {{ namespace }};
44

5-
use Saloon\Contracts\PendingRequest;
5+
use Saloon\Http\PendingRequest;
66

77
trait {{ class }}
88
{

‎src/Console/Commands/stubs/saloon.request.stub‎renamed to ‎stubs/saloon.request.stub‎

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,12 @@ use Saloon\Http\Request;
88
class {{ class }} extends Request
99
{
1010
/**
11-
* Define the HTTP method
12-
*
13-
* @var Method
11+
* The HTTP method of the request
1412
*/
1513
protected Method $method = Method::GET;
1614

1715
/**
18-
* Define the endpoint for the request
19-
*
20-
* @return string
16+
* The endpoint for the request
2117
*/
2218
public function resolveEndpoint(): string
2319
{
File renamed without changes.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp