Skip to content

Commit 6cbdc76

Browse files
authored
Merge pull request #69: Call the method only if there are additional options
2 parents 7f2f426 + 6c0f4fb commit 6cbdc76

File tree

7 files changed

+26
-16
lines changed

7 files changed

+26
-16
lines changed

.github/workflows/ci-mssql.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,12 @@ jobs:
3030
- php: '8.1'
3131
extensions: pdo, pdo_sqlsrv
3232
mssql: 'server:2019-latest'
33+
- php: '8.2'
34+
extensions: pdo, pdo_sqlsrv
35+
mssql: 'server:2019-latest'
36+
- php: '8.3'
37+
extensions: pdo, pdo_sqlsrv
38+
mssql: 'server:2019-latest'
3339

3440
services:
3541
mssql:
@@ -69,11 +75,11 @@ jobs:
6975
run: composer self-update
7076

7177
- name: Install dependencies with composer
72-
if: matrix.php != '8.2'
78+
if: matrix.php != '8.3'
7379
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
7480

75-
- name: Install dependencies with composer php 8.2
76-
if: matrix.php == '8.2'
81+
- name: Install dependencies with composer php 8.3
82+
if: matrix.php == '8.3'
7783
run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
7884

7985
- name: Run tests with phpunit without coverage

.github/workflows/ci-mysql.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@ jobs:
2626
php-version:
2727
- "8.0"
2828
- "8.1"
29+
- "8.2"
30+
- "8.3"
2931

3032
mysql-version:
3133
- "5.7"
@@ -82,11 +84,11 @@ jobs:
8284
php${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-
8385
8486
- name: Install dependencies with composer
85-
if: matrix.php-version != '8.2'
87+
if: matrix.php-version != '8.3'
8688
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
8789

88-
- name: Install dependencies with composer php 8.2
89-
if: matrix.php-version == '8.2'
90+
- name: Install dependencies with composer php 8.3
91+
if: matrix.php-version == '8.3'
9092
run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
9193

9294
- name: Run mysql tests with phpunit

.github/workflows/ci-pgsql.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ jobs:
2525
php-version:
2626
- "8.0"
2727
- "8.1"
28+
- "8.2"
29+
- "8.3"
2830

2931
pgsql-version:
3032
- "10"
@@ -83,11 +85,11 @@ jobs:
8385
php${{ matrix.php-version }}-composer-${{ matrix.dependencies }}-
8486
8587
- name: Install dependencies with composer
86-
if: matrix.php-version != '8.2'
88+
if: matrix.php-version != '8.3'
8789
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
8890

89-
- name: Install dependencies with composer php 8.2
90-
if: matrix.php-version == '8.2'
91+
- name: Install dependencies with composer php 8.3
92+
if: matrix.php-version == '8.3'
9193
run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
9294

9395
- name: Run pgsql tests with phpunit

.github/workflows/main.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
runs-on: ubuntu-latest
1515
strategy:
1616
matrix:
17-
php-versions: ['8.0', '8.1']
17+
php-versions: ['8.0', '8.1', '8.2', '8.3']
1818
steps:
1919
- name: Checkout
2020
uses: actions/checkout@v2
@@ -40,10 +40,10 @@ jobs:
4040
key: ${{ runner.os }}-composer-${{ hashFiles('**/composer.json') }}
4141
restore-keys: ${{ runner.os }}-composer-
4242
- name: Install dependencies with composer
43-
if: matrix.php-versions != '8.2'
43+
if: matrix.php-versions != '8.3'
4444
run: composer update --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
45-
- name: Install dependencies with composer php 8.2
46-
if: matrix.php-versions == '8.2'
45+
- name: Install dependencies with composer php 8.3
46+
if: matrix.php-versions == '8.3'
4747
run: composer update --ignore-platform-reqs --prefer-dist --no-interaction --no-progress --optimize-autoloader --ansi
4848
- name: Execute Tests
4949
run: |

.github/workflows/psalm.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@ jobs:
1515
os: >-
1616
['ubuntu-latest']
1717
php: >-
18-
['8.2']
18+
['8.3']

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
"require": {
99
"php": ">=8.0",
1010
"cycle/orm": "^2.0",
11-
"cycle/database": "^2.5",
11+
"cycle/database": "^2.7.1",
1212
"yiisoft/friendly-exception": "^1.1"
1313
},
1414
"require-dev": {

src/Table/Column.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ public function render(AbstractColumn $column): void
113113

114114
try {
115115
// bypassing call to AbstractColumn->type method (or specialized column method)
116-
if (\method_exists($column, $this->type)) {
116+
if (\method_exists($column, $this->type) && $this->typeOptions !== []) {
117117
call_user_func_array([$column, $this->type], $this->typeOptions);
118118
} else {
119119
call_user_func_array([$column, 'type'], \array_merge([$this->type], $this->typeOptions));

0 commit comments

Comments
 (0)