Skip to content

Commit db0d040

Browse files
committed
Coding standards
1 parent 2343a0c commit db0d040

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

modules/os2forms_fbs_handler/src/Client/FBS.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
/**
1212
* Minimalistic client to create user with guardians at FBS.
1313
*/
14-
class FBS {
14+
class Fbs {
1515

1616
/**
1717
* FBS session key.
@@ -154,12 +154,13 @@ public function getPatron(string $patronId): ?Patron {
154154
(bool) $json->patron->receiveSms,
155155
(bool) $json->patron->receivePostalMail,
156156
$json->patron->notificationProtocols,
157-
$json->patron->phoneNumber,
158157
is_null($json->patron->onHold) ? $json->patron->onHold : (array) $json->patron->onHold,
159158
$json->patron->preferredLanguage,
160159
(bool) $json->patron->guardianVisibility,
161160
$json->patron->defaultInterestPeriod,
162161
(bool) $json->patron->resident,
162+
$json->patron->phoneNumber,
163+
163164
[
164165
[
165166
'emailAddress' => $json->patron->emailAddress,

modules/os2forms_fbs_handler/src/Client/Model/Patron.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,12 @@ public function __construct(
2525
public readonly ?int $defaultInterestPeriod = NULL,
2626
public readonly ?bool $resident = NULL,
2727
// Allow these properties below to be updatable.
28+
public ?string $phoneNumber = NULL,
2829
public ?array $emailAddresses = NULL,
2930
public ?bool $receiveEmail = NULL,
3031
public ?string $preferredPickupBranch = NULL,
3132
public ?string $personId = NULL,
3233
public ?string $pincode = NULL,
33-
public ?string $phoneNumber = NULL,
3434
) {
3535
}
3636

modules/os2forms_fbs_handler/src/Plugin/AdvancedQueue/JobType/FbsCreateUser.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
use Drupal\advancedqueue\Job;
99
use Drupal\advancedqueue\JobResult;
1010
use Drupal\advancedqueue\Plugin\AdvancedQueue\JobType\JobTypeBase;
11-
use Drupal\os2forms_fbs_handler\Client\FBS;
11+
use Drupal\os2forms_fbs_handler\Client\Fbs;
1212
use Drupal\os2forms_fbs_handler\Client\Model\Guardian;
1313
use Drupal\os2forms_fbs_handler\Client\Model\Patron;
1414
use Drupal\os2web_audit\Service\Logger;
@@ -84,7 +84,7 @@ public function process(Job $job): JobResult {
8484
$config = $payload['configuration'];
8585

8686
try {
87-
$fbs = new FBS($this->client, $config['endpoint_url'], $config['agency_id'], $config['username'], $config['password']);
87+
$fbs = new Fbs($this->client, $config['endpoint_url'], $config['agency_id'], $config['username'], $config['password']);
8888

8989
// Log into FBS and obtain session.
9090
$fbs->login();

0 commit comments

Comments
 (0)