v0.12.0
This commit is contained in:
+6
-6
@@ -69,7 +69,7 @@ fn home_assistant_settings(settings: &RuntimeSettings) -> HomeAssistantSettingsV
|
||||
}
|
||||
|
||||
async fn get_application_settings(State(state): State<AppState>) -> Json<ApplicationSettings> {
|
||||
Json(application_settings(&state.settings.read().await))
|
||||
Json(application_settings(&*state.settings.read().await))
|
||||
}
|
||||
|
||||
async fn update_application_settings(
|
||||
@@ -89,7 +89,7 @@ async fn update_application_settings(
|
||||
}
|
||||
|
||||
async fn get_gree_settings(State(state): State<AppState>) -> Json<GreeSettings> {
|
||||
Json(gree_settings(&state.settings.read().await))
|
||||
Json(gree_settings(&*state.settings.read().await))
|
||||
}
|
||||
|
||||
fn normalize_gree_settings(mut input: GreeSettings) -> Result<GreeSettings, AppError> {
|
||||
@@ -169,7 +169,7 @@ async fn update_gree_settings(
|
||||
}
|
||||
|
||||
async fn get_history_settings(State(state): State<AppState>) -> Json<HistorySettings> {
|
||||
Json(history_settings(&state.settings.read().await))
|
||||
Json(history_settings(&*state.settings.read().await))
|
||||
}
|
||||
|
||||
async fn update_history_settings(
|
||||
@@ -198,7 +198,7 @@ async fn update_history_settings(
|
||||
}
|
||||
|
||||
async fn get_influxdb_settings(State(state): State<AppState>) -> Json<InfluxDbSettingsView> {
|
||||
Json(influxdb_settings(&state.settings.read().await))
|
||||
Json(influxdb_settings(&*state.settings.read().await))
|
||||
}
|
||||
|
||||
fn apply_influxdb_update(current: &InfluxDbSettings, input: InfluxDbSettingsUpdate) -> Result<InfluxDbSettings, AppError> {
|
||||
@@ -238,7 +238,7 @@ async fn update_influxdb_settings(
|
||||
}
|
||||
|
||||
async fn get_notification_settings(State(state): State<AppState>) -> Json<NotificationSettingsView> {
|
||||
Json(notification_settings(&state.settings.read().await))
|
||||
Json(notification_settings(&*state.settings.read().await))
|
||||
}
|
||||
|
||||
fn apply_notification_update(current: &NotificationSettings, mut input: NotificationSettingsUpdate) -> Result<NotificationSettings, AppError> {
|
||||
@@ -320,7 +320,7 @@ async fn update_night_settings(
|
||||
}
|
||||
|
||||
async fn get_home_assistant_settings(State(state): State<AppState>) -> Json<HomeAssistantSettingsView> {
|
||||
Json(home_assistant_settings(&state.settings.read().await))
|
||||
Json(home_assistant_settings(&*state.settings.read().await))
|
||||
}
|
||||
|
||||
fn normalize_sensor_aliases(settings: &mut HomeAssistantSettings) {
|
||||
|
||||
Reference in New Issue
Block a user