projects
/
SonOfLokstallBot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2b0b62c
)
Add function to get message sender ID
author
Cameron Ball
<cameron@cameron1729.xyz>
Sat, 22 Dec 2018 07:07:43 +0000
(15:07 +0800)
committer
Cameron Ball
<cameron@cameron1729.xyz>
Fri, 28 Dec 2018 06:27:20 +0000
(14:27 +0800)
common.php
patch
|
blob
|
history
diff --git
a/common.php
b/common.php
index
7967015
..
f633c70
100644
(file)
--- a/
common.php
+++ b/
common.php
@@
-24,7
+24,11
@@
function notEmpty($value) {
}
function getMessageSender($update) {
- return PARTICIPANT_IDS[$update->get('message')->get('from')->get('id')];
+ return PARTICIPANT_IDS[getMessageSenderId($update)];
+}
+
+function getMessageSenderId($update) {
+ return $update->get('message')->get('from')->get('id');
}
function getMessageSenderDisplayName($update) {