johndeniel commited on
Commit
18606d8
1 Parent(s): feb4822

Update src/router/routes.rs

Browse files
Files changed (1) hide show
  1. src/router/routes.rs +15 -15
src/router/routes.rs CHANGED
@@ -1,15 +1,15 @@
1
- use axum::{routing::get, Router};
2
- use axum::response::{Html, IntoResponse};
3
- use crate::spotify::playlist;
4
- use std::fs;
5
-
6
- pub fn app() -> Router {
7
- Router::new()
8
- .route("/", get(serve_html))
9
- .route("/playlist", get(playlist::get_playlist_json))
10
- }
11
-
12
- async fn serve_html() -> impl IntoResponse {
13
- let html_content = fs::read_to_string("src/static/index.html").unwrap();
14
- Html(html_content)
15
- }
 
1
+ use axum::{routing::get, Router};
2
+ use axum::response::{Html, IntoResponse};
3
+ use crate::spotify::playlist;
4
+ use std::fs;
5
+
6
+ pub fn app() -> Router {
7
+ Router::new()
8
+ .route("/", get(serve_html))
9
+ .route("/playlist", get(playlist::get_playlist_json))
10
+ }
11
+
12
+ async fn serve_html() -> impl IntoResponse {
13
+ let html_content = fs::read_to_string("/usr/local/bin/static/index.html").unwrap();
14
+ Html(html_content)
15
+ }