aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Cargo.lock2
-rw-r--r--Cargo.toml3
-rw-r--r--src/eorzean_weather.rs2
3 files changed, 4 insertions, 3 deletions
diff --git a/Cargo.lock b/Cargo.lock
index d346a66..47825d1 100644
--- a/Cargo.lock
+++ b/Cargo.lock
@@ -66,7 +66,7 @@ checksum = "773648b94d0e5d620f64f280777445740e61fe701025087ec8b57f45c791888b"
[[package]]
name = "ffxiv-chronowatcher"
-version = "0.0.3"
+version = "0.0.32"
dependencies = [
"chrono",
"serde",
diff --git a/Cargo.toml b/Cargo.toml
index c16fafa..a516a34 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -4,11 +4,12 @@ description = "Weather and Eorzean Time Library for Final Fantasy XIV"
repository = "https://github.com/pinapelz/ffxiv-chronowatcher"
readme = "README.md"
keywords = ["ffxiv", "eorzea", "weather", "time"]
-version = "0.0.3"
+version = "0.0.32"
edition = "2021"
exclude = [
"src/main.rs",
]
+
license = "MIT"
[dependencies]
diff --git a/src/eorzean_weather.rs b/src/eorzean_weather.rs
index 3badd0f..a462627 100644
--- a/src/eorzean_weather.rs
+++ b/src/eorzean_weather.rs
@@ -175,7 +175,7 @@ pub fn calculate_weather_forecast_target<T: ToUnixTimestamp>(current_time: T) ->
/// - A Weather struct representing the current weather
pub fn get_weather_by_time<T: ToUnixTimestamp>(zone_name: &str, current_time: T) -> Weather {
// Load the weather data from the JSON file
- let weather_data = fs::read_to_string("data/weather_data.json").expect("Unable to read the weather data file");
+ let weather_data = include_str!("../data/weather_data.json");
let weather_data: serde_json::Value = serde_json::from_str(&weather_data).expect("Unable to parse the weather data");
let zone_data = weather_data
.get(zone_name)
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage