Compare commits
2 Commits
Author | SHA1 | Date | |
---|---|---|---|
d237909b6d | |||
7dfaac06e4 |
4
.github/workflows/tests.yml
vendored
4
.github/workflows/tests.yml
vendored
@ -15,7 +15,7 @@ jobs:
|
||||
|
||||
strategy:
|
||||
matrix:
|
||||
php-version: ['7.4', '8.0']
|
||||
php-version: ['7.4', '8.0', '8.1']
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
@ -55,7 +55,7 @@ jobs:
|
||||
|
||||
- name: Run SonarQube analysis
|
||||
uses: sonarsource/sonarcloud-github-action@master
|
||||
if: matrix.php-version == '8.0'
|
||||
if: matrix.php-version == '8.1'
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
SONAR_TOKEN: ${{ secrets.SONARCLOUD_TOKEN }}
|
||||
|
@ -20,8 +20,8 @@
|
||||
],
|
||||
"require": {
|
||||
"php": "^7.4|^8.0",
|
||||
"illuminate/config": "~7.0|~8.0",
|
||||
"illuminate/support": "~7.0|~8.0",
|
||||
"illuminate/config": "~7.0|~8.0|~9.0",
|
||||
"illuminate/support": "~7.0|~8.0|~9.0",
|
||||
"php-mqtt/client": "^1.0"
|
||||
},
|
||||
"require-dev": {
|
||||
|
@ -60,6 +60,12 @@ class ConnectionManager
|
||||
$name = $this->defaultConnection;
|
||||
}
|
||||
|
||||
// Remove the connection if it is in a disconnected state.
|
||||
// Doing this instead of simply reconnecting ensures the caller will get a fresh connection.
|
||||
if (array_key_exists($name, $this->connections) && !$this->connections[$name]->isConnected()) {
|
||||
unset($this->connections[$name]);
|
||||
}
|
||||
|
||||
if (!array_key_exists($name, $this->connections)) {
|
||||
$this->connections[$name] = $this->createConnection($name);
|
||||
}
|
||||
|
Reference in New Issue
Block a user