Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
TelegramBot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Kulya
TelegramBot
Commits
c37c17dc
Unverified
Commit
c37c17dc
authored
Aug 02, 2017
by
Armando Lüscher
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Send /cleanup response to private user chat instead of current chat.
parent
ecb9e774
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
8 deletions
+2
-8
CleanupCommand.php
src/Commands/AdminCommands/CleanupCommand.php
+2
-8
No files found.
src/Commands/AdminCommands/CleanupCommand.php
View file @
c37c17dc
...
@@ -351,20 +351,14 @@ class CleanupCommand extends AdminCommand
...
@@ -351,20 +351,14 @@ class CleanupCommand extends AdminCommand
public
function
execute
()
public
function
execute
()
{
{
$message
=
$this
->
getMessage
();
$message
=
$this
->
getMessage
();
$
chat_id
=
$message
->
getChat
()
->
getId
();
$
user_id
=
$message
->
getFrom
()
->
getId
();
$text
=
$message
->
getText
(
true
);
$text
=
$message
->
getText
(
true
);
$data
=
[
$data
=
[
'chat_id'
=>
$
chat
_id
,
'chat_id'
=>
$
user
_id
,
'parse_mode'
=>
'Markdown'
,
'parse_mode'
=>
'Markdown'
,
];
];
if
(
!
$message
->
getChat
()
->
isPrivateChat
())
{
$data
[
'text'
]
=
'/cleanup command is only available in a private chat.'
;
return
Request
::
sendMessage
(
$data
);
}
$settings
=
$this
->
getSettings
(
$text
);
$settings
=
$this
->
getSettings
(
$text
);
$queries
=
$this
->
getQueries
(
$settings
);
$queries
=
$this
->
getQueries
(
$settings
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment