TMessage reply fix
This commit is contained in:
parent
1659af328f
commit
969400f9c7
|
@ -22,11 +22,11 @@ public class TMessage extends JSONBased {
|
|||
throw new RuntimeException("not implemented");
|
||||
}
|
||||
|
||||
public boolean reply(String msg) {
|
||||
public boolean reply(String msg, TReplyMarkup rm) {
|
||||
if(from == null) {
|
||||
throw new RuntimeException("no from defined!");
|
||||
} else {
|
||||
return from.sendMessage(msg, null, message_id);
|
||||
return TUser.sendMessage(api, chatid != 0 ? chatid : from.getID(), msg, rm, message_id);
|
||||
}
|
||||
// try {
|
||||
// return api.request("sendMessage", "chat_id=" + from.getID() + "&text=" + msg + "&reply_to_message_id=" + message_id ).getBoolean("ok") ;
|
||||
|
@ -35,6 +35,9 @@ public class TMessage extends JSONBased {
|
|||
// return false;
|
||||
// }
|
||||
}
|
||||
public boolean reply(String msg) {
|
||||
return reply(msg, null);
|
||||
}
|
||||
|
||||
public TMessage forward(TUser us) {
|
||||
return forward(api, us.getID(), this);
|
||||
|
|
Loading…
Reference in New Issue