Skip to content

Commit 65d48a7

Browse files
committed
Remove BC breaking Webmozart asserts
1 parent 0c28a48 commit 65d48a7

File tree

2 files changed

+5
-8
lines changed

2 files changed

+5
-8
lines changed

composer.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,7 @@
2828
},
2929
"require": {
3030
"php": ">=5.6",
31-
"simplesamlphp/composer-module-installer": "~1.1",
32-
"webmozart/assert": "~1.4"
31+
"simplesamlphp/composer-module-installer": "~1.1"
3332
},
3433
"require-dev": {
3534
"simplesamlphp/simplesamlphp": "^1.17",

lib/Auth/Source/Radius.php

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22

33
namespace SimpleSAML\Module\radius\Auth\Source;
44

5-
use Webmozart\Assert\Assert;
6-
75
/**
86
* RADIUS authentication source.
97
*
@@ -78,8 +76,8 @@ class Radius extends \SimpleSAML\Module\core\Auth\UserPassBase
7876
*/
7977
public function __construct($info, $config)
8078
{
81-
Assert::isArray($info);
82-
Assert::isArray($config);
79+
assert(is_array($info));
80+
assert(is_array($config));
8381

8482
// Call the parent constructor first, as required by the interface
8583
parent::__construct($info, $config);
@@ -127,8 +125,8 @@ public function __construct($info, $config)
127125
*/
128126
protected function login($username, $password)
129127
{
130-
Assert::string($username);
131-
Assert::string($password);
128+
assert(is_string($username));
129+
assert(is_string($password));
132130

133131
$radius = radius_auth_open();
134132
if (!is_resource($radius)) {

0 commit comments

Comments
 (0)