Added round to coordinates
This commit is contained in:
@@ -287,8 +287,8 @@ async def continue_or_finish(update: Update, context: CallbackContext):
|
||||
if last_step == 'coords':
|
||||
answer = update.message.text
|
||||
try:
|
||||
latitude = float(answer.split(',')[0])
|
||||
longitude = float(answer.split(',')[1])
|
||||
latitude = round(float(answer.split(',')[0]), 4)
|
||||
longitude = round(float(answer.split(',')[1]), 4)
|
||||
except:
|
||||
await context.bot.send_message(chat_id=update.effective_chat.id,
|
||||
text='Pon las coordenadas siguiendo el ejemplo: 41.34, 0.65', reply_markup=ForceReply())
|
||||
|
||||
Reference in New Issue
Block a user