Skip to content

Adds delete Account functionality#215

Open
EndoSkeletor wants to merge 1 commit into
cloudflare:masterfrom
EndoSkeletor:213-delete-an-account
Open

Adds delete Account functionality#215
EndoSkeletor wants to merge 1 commit into
cloudflare:masterfrom
EndoSkeletor:213-delete-an-account

Conversation

@EndoSkeletor

Copy link
Copy Markdown

Resolves #213

@PululuK PululuK left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks @EndoSkeletor
A small feedback :)

Comment on lines +57 to +65
public function deleteAccount(string $account_id): \stdClass
{
$identifier = $account_id;

$user = $this->adapter->delete('accounts/' . $identifier);
$this->body = json_decode($user->getBody());

return (object)['result' => $this->body->result];
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
public function deleteAccount(string $account_id): \stdClass
{
$identifier = $account_id;
$user = $this->adapter->delete('accounts/' . $identifier);
$this->body = json_decode($user->getBody());
return (object)['result' => $this->body->result];
}
public function deleteAccount(string $account_id): \stdClass
{
$user = $this->adapter->delete('accounts/' . $account_id);
$this->body = json_decode($user->getBody());
return (object)['result' => $this->body->result];
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Delete an Account

2 participants