Skip to content

Commit 6e10bdc

Browse files
chore: update PHP wrapper (#1353)
## 🎟️ Tracking https://bitwarden.atlassian.net/browse/SM-1620 ## 📔 Objective Update PHP bindings to work with newer sdk. ## ⏰ Reminders before review - Contributor guidelines followed - All formatters and local linters executed and passed - Written new unit and / or integration tests where applicable - Protected functional changes with optionality (feature flags) - Used internationalization (i18n) for all UI strings - CI builds passed - Communicated to DevOps any deployment requirements - Updated any necessary documentation (Confluence, contributing docs) or informed the documentation team ## 🦮 Reviewer guidelines <!-- Suggested interactions but feel free to use (or not) as you desire! --> - 👍 (`:+1:`) or similar for great changes - 📝 (`:memo:`) or ℹ️ (`:information_source:`) for notes or general info - ❓ (`:question:`) for questions - 🤔 (`:thinking:`) or 💭 (`:thought_balloon:`) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion - 🎨 (`:art:`) for suggestions / improvements - ❌ (`:x:`) or ⚠️ (`:warning:`) for more significant problems or concerns needing attention - 🌱 (`:seedling:`) or ♻️ (`:recycle:`) for future improvements or indications of technical debt - ⛏ (`:pick:`) for minor or nitpick changes
1 parent 8a97090 commit 6e10bdc

File tree

4 files changed

+7
-9
lines changed

4 files changed

+7
-9
lines changed

languages/php/composer.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

languages/php/src/AuthClient.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ public function __construct(CommandRunner $commandRunner)
2121
public function login_access_token(string $access_token, ?string $state_file): void
2222
{
2323
$access_token_request = new AccessTokenLoginRequest($access_token, $state_file);
24-
$command = new Command(passwordLogin: null, apiKeyLogin: null, loginAccessToken: $access_token_request,
25-
getUserApiKey: null, fingerprint: null, sync: null, secrets: null, projects: null, generators: null);
24+
$command = new Command(loginAccessToken: $access_token_request,
25+
secrets: null, projects: null, generators: null, debug: null);
2626
try {
2727
$result = $this->commandRunner->run($command);
2828
if (!isset($result->authenticated) || !$result->authenticated) {

languages/php/src/ProjectsClient.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,7 @@ public function delete(array $ids): stdClass
8787
*/
8888
public function run_project_command($projectCommand): stdClass
8989
{
90-
$command = new Command(passwordLogin: null, apiKeyLogin: null, loginAccessToken: null, getUserApiKey: null,
91-
fingerprint: null, sync: null, secrets: null, projects: $projectCommand, generators: null);
90+
$command = new Command(loginAccessToken: null, secrets: null, projects: $projectCommand, generators: null, debug: null);
9291
return $this->commandRunner->run($command);
9392
}
9493
}

languages/php/src/SecretsClient.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,8 +118,7 @@ public function sync(string $organization_id, ?string $last_synced_date): stdCla
118118
*/
119119
public function run_secret_command($secretsCommand): stdClass
120120
{
121-
$command = new Command(passwordLogin: null, apiKeyLogin: null, loginAccessToken: null, getUserApiKey: null,
122-
fingerprint: null, sync: null, secrets: $secretsCommand, projects: null, generators: null);
121+
$command = new Command(loginAccessToken: null, secrets: $secretsCommand, projects: null, generators: null, debug: null);
123122
return $this->commandRunner->run($command);
124123
}
125124
}

0 commit comments

Comments
 (0)