Skip to content

Commit 7a66f4a

Browse files
author
Helperhaps
committed
Merge branch 'dev'
2 parents c4e23cb + a3a1aae commit 7a66f4a

File tree

3 files changed

+5
-7
lines changed

3 files changed

+5
-7
lines changed

examples/push_example.php

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,15 +12,14 @@
1212
->setNotificationAlert('Hi, JPush');
1313
try {
1414
$response = $push_payload->send();
15-
}catch (\JPush\Exceptions\APIConnectionException $e) {
15+
print_r($response);
16+
} catch (\JPush\Exceptions\APIConnectionException $e) {
1617
// try something here
1718
print $e;
1819
} catch (\JPush\Exceptions\APIRequestException $e) {
1920
// try something here
2021
print $e;
2122
}
22-
print_r($response);
23-
2423

2524
// 完整的推送示例
2625
// 这只是使用样例,不应该直接用于实际生产环境中 !!
@@ -89,6 +88,7 @@
8988
// 'big_push_duration' => 1
9089
))
9190
->send();
91+
print_r($response);
9292

9393
} catch (\JPush\Exceptions\APIConnectionException $e) {
9494
// try something here
@@ -97,5 +97,3 @@
9797
// try something here
9898
print $e;
9999
}
100-
101-
print_r($response);

src/JPush/Exceptions/APIConnectionException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
class APIConnectionException extends JPushException {
55

66
function __toString() {
7-
return "\n" . __CLASS__ . " -- {$message} \n";
7+
return "\n" . __CLASS__ . " -- {$this->message} \n";
88
}
99
}

src/JPush/version.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
<?php
22
namespace JPush;
33

4-
const VERSION = '3.5.10';
4+
const VERSION = '3.5.11';

0 commit comments

Comments
 (0)