Reorder exits
This commit is contained in:
		
							
								
								
									
										14
									
								
								webhook.php
									
									
									
									
									
								
							
							
						
						
									
										14
									
								
								webhook.php
									
									
									
									
									
								
							| @@ -215,11 +215,6 @@ fwrite($json, $var); | |||||||
| fclose($json); | fclose($json); | ||||||
| $decoded = json_decode($var); | $decoded = json_decode($var); | ||||||
|  |  | ||||||
| // If message is a reply, exit |  | ||||||
| if (isset($decoded->{"message"}->{"reply_to_message"})) { |  | ||||||
|   exit(); |  | ||||||
| } |  | ||||||
|  |  | ||||||
| // Store the chat ID | // Store the chat ID | ||||||
| $chat_id = $decoded->{"message"}->{"chat"}->{"id"}; | $chat_id = $decoded->{"message"}->{"chat"}->{"id"}; | ||||||
|  |  | ||||||
| @@ -282,6 +277,10 @@ $modules = array( | |||||||
|   ) |   ) | ||||||
| ); | ); | ||||||
|  |  | ||||||
|  | if (!isset($decoded->{"message"}->{"text"})){ | ||||||
|  |    exit(); | ||||||
|  | } | ||||||
|  |  | ||||||
| if (isset($decoded->{"message"}->{"pinned_message"})){ | if (isset($decoded->{"message"}->{"pinned_message"})){ | ||||||
|    exit(); |    exit(); | ||||||
| } | } | ||||||
| @@ -294,8 +293,11 @@ foreach ($modules as $module ) { | |||||||
|     exit(); |     exit(); | ||||||
|   } |   } | ||||||
| } | } | ||||||
| if (!isset($decoded->{"message"}->{"text"})){ |  | ||||||
|  | // If message is a reply, exit | ||||||
|  | if (isset($decoded->{"message"}->{"reply_to_message"})) { | ||||||
|   exit(); |   exit(); | ||||||
| } | } | ||||||
|  |  | ||||||
| send_text(get_insults(), true); | send_text(get_insults(), true); | ||||||
| ?> | ?> | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user