Serve directly from root
Signed-off-by: baalajimaestro <me@baalajimaestro.me>
This commit is contained in:
parent
e21c1a73a6
commit
69a3c01a06
2 changed files with 2 additions and 2 deletions
|
@ -53,7 +53,7 @@ async fn paste_render(data: Data<Template>, paste: Query<Paste>) -> impl Respond
|
|||
headers.insert("PRIVATE-TOKEN", gitlab_token.parse().unwrap());
|
||||
let paste_content: String;
|
||||
if paste.paste_id.is_some() {
|
||||
let response = client.get(format!("{}/repository/files/paste%2F{}.md?ref=master", base_url, paste.paste_id.as_ref().unwrap())).headers(headers).send().await.unwrap();
|
||||
let response = client.get(format!("{}/repository/files/{}?ref=master", base_url, paste.paste_id.as_ref().unwrap())).headers(headers).send().await.unwrap();
|
||||
let response_code = response.status().as_str().to_string();
|
||||
let response_json = response.text().await.unwrap();
|
||||
if response_code != "200" {
|
||||
|
|
|
@ -72,4 +72,4 @@
|
|||
</script>
|
||||
<!-- End Matomo Code -->
|
||||
</body>
|
||||
</html>
|
||||
</html>
|
||||
|
|
Loading…
Reference in a new issue