mirror of
https://github.com/1sept/oauth2-1sept.git
synced 2024-05-30 17:38:52 +03:00
Compare commits
7 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 447926e3d1 | |||
| 3cd9556bd7 | |||
| 91ffe0f7f6 | |||
| d95d71e571 | |||
| 5ab62ace79 | |||
| 0b2c6b6c31 | |||
| 66ae333e6a |
39
.github/workflows/php.yml
vendored
Normal file
39
.github/workflows/php.yml
vendored
Normal file
@@ -0,0 +1,39 @@
|
||||
name: PHP Composer
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "main" ]
|
||||
pull_request:
|
||||
branches: [ "main" ]
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
jobs:
|
||||
build:
|
||||
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
||||
- name: Validate composer.json and composer.lock
|
||||
run: composer validate --strict
|
||||
|
||||
- name: Cache Composer packages
|
||||
id: composer-cache
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: vendor
|
||||
key: ${{ runner.os }}-php-${{ hashFiles('**/composer.lock') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-php-
|
||||
|
||||
- name: Install dependencies
|
||||
run: composer install --prefer-dist --no-progress
|
||||
|
||||
# Add a test script to composer.json, for instance: "test": "vendor/bin/phpunit"
|
||||
# Docs: https://getcomposer.org/doc/articles/scripts.md
|
||||
|
||||
- name: Run test suite
|
||||
run: composer run test
|
||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,5 +1,6 @@
|
||||
/build
|
||||
/vendor
|
||||
.phpunit.cache
|
||||
composer.phar
|
||||
composer.lock
|
||||
.DS_Store
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
{"version":1,"defects":{"Sept\\OAuth2\\Client\\Test\\UserTest::testCreate":5},"times":{"Sept\\OAuth2\\Client\\Test\\UserTest::testCreate":0.001}}
|
||||
@@ -17,7 +17,7 @@
|
||||
"1sept"
|
||||
],
|
||||
"require": {
|
||||
"php": "^7.3 || ^8",
|
||||
"php": "^8.2",
|
||||
"league/oauth2-client": "^2.0"
|
||||
},
|
||||
"require-dev": {
|
||||
|
||||
@@ -84,7 +84,7 @@ class SeptemberFirstProvider extends GenericProvider
|
||||
protected function checkResponse(ResponseInterface $response, $data): void
|
||||
{
|
||||
if (isset($data['error'])) {
|
||||
throw new IdentityProviderException($data['error'].': '.$data['message'], 0, $response);
|
||||
throw new IdentityProviderException($data['error']. (isset($data['message']) ? ': '.$data['message'] : ''), 0, $response);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user