Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

General: Fix typos #88

Merged
merged 1 commit into from
Jul 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion ApnsPHP/Message.php
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ public function selfForRecipient(int $recipient = 0)
);
}

//TODO: Replace this with actuall looping over recipients
//TODO: Replace this with actually looping over recipients
$copy = clone $this;
$copy->deviceTokens = [$this->deviceTokens[$recipient]];

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public function testGetPayloadDictionaryReturnsCompletePayloadWithoutLocKey(): v
$this->class->setMutableContent(true);
$this->class->setCategory('something');
$this->class->setThreadId('thisIsAThreadId');
$this->class->setCustomProperty('propertie', 'propertie');
$this->class->setCustomProperty('property', 'property');
$this->class->setCustomProperty('name', 'value');
$this->class->setActionLocKey('Button title');
$this->class->setLocArgs([ 'value', 'value' ]);
Expand All @@ -56,7 +56,7 @@ public function testGetPayloadDictionaryReturnsCompletePayloadWithoutLocKey(): v
'category' => 'something',
'thread-id' => 'thisIsAThreadId'
],
'propertie' => 'propertie',
'property' => 'property',
'name' => 'value'
];

Expand All @@ -80,7 +80,7 @@ public function testGetPayloadDictionaryReturnsCompletePayloadWithoutBody(): voi
$this->class->setMutableContent(true);
$this->class->setCategory('something');
$this->class->setThreadId('thisIsAThreadId');
$this->class->setCustomProperty('propertie', 'propertie');
$this->class->setCustomProperty('property', 'property');
$this->class->setCustomProperty('name', 'value');
$this->class->setActionLocKey('Button title');
$this->class->setLocKey('localization string');
Expand All @@ -105,7 +105,7 @@ public function testGetPayloadDictionaryReturnsCompletePayloadWithoutBody(): voi
'category' => 'something',
'thread-id' => 'thisIsAThreadId'
],
'propertie' => 'propertie',
'property' => 'property',
'name' => 'value'
];

Expand Down
2 changes: 1 addition & 1 deletion ApnsPHP/Push.php
Original file line number Diff line number Diff line change
Expand Up @@ -661,7 +661,7 @@ private function httpSend(Message $message, &$reply): bool
*
* When a message is successful sent or reached the maximum retry time is removed
* from the message queue and inserted in the Errors container. Use the getErrors()
* method to retrive messages with delivery error(s).
* method to retrieve messages with delivery error(s).
*
* @param bool $empty Empty the message queue (optional).
*
Expand Down
8 changes: 4 additions & 4 deletions ApnsPHP/Tests/MessageGetPayloadTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,12 +32,12 @@ public function testGetPayloadReturnsCompletePayload(): void
$this->class->setMutableContent(true);
$this->class->setCategory('something');
$this->class->setThreadId('thisIsAThreadId');
$this->class->setCustomProperty('propertie', 'propertie');
$this->class->setCustomProperty('property', 'property');
$this->class->setCustomProperty('name', 'value');

$payload = '{"aps":{"alert":{"title":"Were no strangers to love","body":"You know the rules, and so do I"},' .
'"badge":1,"sound":"default","content-available":1,"mutable-content":1,"category":"something",' .
'"thread-id":"thisIsAThreadId"},"propertie":"propertie","name":"value"}';
'"thread-id":"thisIsAThreadId"},"property":"property","name":"value"}';

$result = $this->class->getPayload();

Expand Down Expand Up @@ -126,12 +126,12 @@ public function testCastToStringReturnsCompletePayload(): void
$this->class->setMutableContent(true);
$this->class->setCategory('something');
$this->class->setThreadId('thisIsAThreadId');
$this->class->setCustomProperty('propertie', 'propertie');
$this->class->setCustomProperty('property', 'property');
$this->class->setCustomProperty('name', 'value');

$payload = '{"aps":{"alert":{"title":"Were no strangers to love","body":"You know the rules, and so do I"},' .
'"badge":1,"sound":"default","content-available":1,"mutable-content":1,"category":"something",' .
'"thread-id":"thisIsAThreadId"},"propertie":"propertie","name":"value"}';
'"thread-id":"thisIsAThreadId"},"property":"property","name":"value"}';

$result = (string) $this->class;

Expand Down
4 changes: 2 additions & 2 deletions ApnsPHP/Tests/MessageGetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ public function testGetCustomPropertyValueThrowsExceptionWhenNoneSet(): void
}

/**
* Test that getCustomPropertyValue() successfuly returns an existing property.
* Test that getCustomPropertyValue() successfully returns an existing property.
*
* @covers \ApnsPHP\Message::getCustomProperty
*/
Expand Down Expand Up @@ -330,7 +330,7 @@ public function testGetCustomPropertyThrowsExceptionWhenNotExists(): void
}

/**
* Test that getCustomPropertyNames() successfuly returns the names of the set properties.
* Test that getCustomPropertyNames() successfully returns the names of the set properties.
*
* @covers \ApnsPHP\Message::getCustomPropertyNames
*/
Expand Down
4 changes: 2 additions & 2 deletions ApnsPHP/Tests/MessageSetTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -364,7 +364,7 @@ public function testSetInvalidCustomProperty(string $key): void
* @dataProvider validCustomIdentifierProvider
* @covers \ApnsPHP\Message::setCustomIdentifier
*/
public function testSetValidCustomIndentifier(string $id): void
public function testSetValidCustomIdentifier(string $id): void
{
$this->class->setCustomIdentifier($id);

Expand All @@ -376,7 +376,7 @@ public function testSetValidCustomIndentifier(string $id): void
*
* @covers \ApnsPHP\Message::setCustomIdentifier
*/
public function testSetInvalidCustomIndentifier(): void
public function testSetInvalidCustomIdentifier(): void
{
$this->expectException('ApnsPHP\Message\Exception');
$this->expectExceptionMessage('Identifier must be a UUID');
Expand Down
2 changes: 1 addition & 1 deletion sample_push_custom.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function log($level, $message, array $context = []): void
}
}

// Instanciate a new ApnsPHP_Push object
// Instantiate a new ApnsPHP_Push object
$push = new \ApnsPHP\Push(
\ApnsPHP\Push::ENVIRONMENT_SANDBOX,
'server_certificates_bundle_sandbox.pem',
Expand Down
2 changes: 1 addition & 1 deletion sample_push_many.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public function log($level, $message, array $context = []): void
}
}

// Instanciate a new ApnsPHP_Push object
// Instantiate a new ApnsPHP_Push object
$push = new \ApnsPHP\Push(
\ApnsPHP\Push::ENVIRONMENT_SANDBOX,
'server_certificates_bundle_sandbox.pem',
Expand Down
Loading