Skip to content

Commit

Permalink
Migrate away from push categories, tweak actions to be an array
Browse files Browse the repository at this point in the history
  • Loading branch information
adamjernst committed Feb 1, 2024
1 parent 562952e commit 90abc8a
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions src/websocket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -238,12 +238,14 @@ async fn handle_plate(
});
if plate_name.is_none() {
// Use an actionable notification to allow specifying the name.
service_data["data"]["actions"] = json!({
"action": "REPLY",
"title": "Save Name...",
"textInputButtonTitle": "Save",
"textInputPlaceholder": "e.g. \"John\" or \"Trash Pickup\"",
});
service_data["data"]["actions"] = json!([
{
"action": "REPLY",
"title": "Save Name...",
"textInputButtonTitle": "Save",
"textInputPlaceholder": "e.g. 'John' or 'Trash Pickup'",
}
]);
service_data["data"]["action_data"] = json!({"plate": spotted_plate.plate});
}
if let Some(ref url) = spotted_plate.image_url {
Expand Down

0 comments on commit 90abc8a

Please sign in to comment.