Skip to content

Commit 27ac78d

Browse files
committed
Merge branch 'release/3.2.0'
2 parents fc45aa2 + ea1bc27 commit 27ac78d

File tree

6 files changed

+40
-12
lines changed

6 files changed

+40
-12
lines changed

.github/workflows/php.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
strategy:
1515
fail-fast: true
1616
matrix:
17-
php: [ 8.0, 7.4 ]
17+
php: [ 8.0 ]
1818
stability: [ prefer-lowest, prefer-stable ]
1919

2020
name: PHP ${{ matrix.php }} - ${{ matrix.stability }}

.gitignore

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
1-
composer.lock
2-
.idea/
1+
/.idea
2+
/composer.lock
3+
/vendor
4+
/modules

CHANGELOG.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,27 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [3.2.0] - 2022-09-23
8+
9+
### Added
10+
11+
- Basic Authentication added to October CMS backend routes.
12+
13+
### Removed
14+
15+
- Removed support for October CMS 1.0
16+
- Removed support for PHP 7.4
17+
718
## [3.1.0] - 2022-04-12
819

20+
### Added
21+
922
- Add October CMS 3.x to supported versions.
1023

1124
## [3.0.2] - 2022-03-22
1225

26+
### Changed
27+
1328
- Rename migration class (duplicate class name).
1429

1530
## [3.0.1] - 2022-03-15

Plugin.php

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@
55
namespace Vdlp\BasicAuthentication;
66

77
use Backend\Helpers\Backend as BackendHelper;
8+
use Illuminate\Routing\Router;
89
use October\Rain\Foundation\Application;
9-
use October\Rain\Foundation\Http\Kernel;
1010
use System\Classes\PluginBase;
1111
use Vdlp\BasicAuthentication\Console\CreateCredentialsCommand;
1212
use Vdlp\BasicAuthentication\Http\Middleware\BasicAuthenticationMiddleware;
@@ -40,14 +40,13 @@ public function boot(): void
4040
(bool) config('basicauthentication.enabled', false) === false
4141
|| $application->runningInConsole()
4242
|| $application->runningUnitTests()
43-
|| $application->runningInBackend()
4443
) {
4544
return;
4645
}
4746

48-
/** @var Kernel $kernel */
49-
$kernel = $application['Illuminate\Contracts\Http\Kernel'];
50-
$kernel->prependMiddleware(BasicAuthenticationMiddleware::class);
47+
/** @var Router $router */
48+
$router = $application->make(Router::class);
49+
$router->pushMiddlewareToGroup('web', BasicAuthenticationMiddleware::class);
5150
}
5251

5352
public function registerPermissions(): array

composer.json

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "vdlp/oc-basicauthentication-plugin",
33
"description": "Protect your website with Basic Authentication.",
4-
"license": "GPL-2.0",
4+
"license": "GPL-2.0-only",
55
"type": "october-plugin",
66
"authors": [
77
{
@@ -13,15 +13,26 @@
1313
"email": "[email protected]"
1414
},
1515
"require": {
16-
"php": "^7.4 || ^8.0",
17-
"october/system": "^1.0 || ^2.0 || ^3.0",
18-
"composer/installers": "^1.0 || ^2.0"
16+
"php": "^8.0.2",
17+
"composer/installers": "^1.0 || ^2.0",
18+
"october/system": ">=2.0"
1919
},
20+
"repositories": [
21+
{
22+
"type": "composer",
23+
"url": "https://gateway.octobercms.com"
24+
}
25+
],
2026
"archive": {
2127
"exclude": [
2228
".gitattributes",
2329
".gitignore",
2430
".github"
2531
]
32+
},
33+
"config": {
34+
"allow-plugins": {
35+
"composer/installers": true
36+
}
2637
}
2738
}

updates/version.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,3 +14,4 @@ v3.0.1:
1414
v3.0.2:
1515
- "Rename migration class (duplicate class name)."
1616
v3.1.0: "Add October CMS 3.x to supported versions."
17+
v3.2.0: "Basic Authentication added to October CMS backend routes."

0 commit comments

Comments
 (0)