Add Emoji to Meteo

This commit is contained in:
LucasVbr
2022-06-06 17:56:26 +02:00
parent 512c0896c0
commit 2707eecbd9
3 changed files with 75 additions and 4 deletions
+3 -1
View File
@@ -5,6 +5,7 @@ from flask import Flask, render_template
from src.Badge import Badge, getBadgeColor
from meteofrance_api import MeteoFranceClient
from src.FileUtils import setFileData, getJsonData
from src.meteoEmoji import EMOJIS
"""
05/06/2022
@@ -38,7 +39,8 @@ def getWeather(city: str) -> dict:
return {
"temperature": weather.get('T').get('value'),
"description": weather.get("weather").get("desc")
"description": weather.get("weather").get("desc"),
"icon": EMOJIS.get(weather.get("weather").get("icon"))
}