aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCeleste <colean@colean.cc>2021-12-26 17:31:46 +0000
committerCeleste <colean@colean.cc>2021-12-26 17:31:46 +0000
commit9f28bcdb84a9a95add8ac9203d4dfc8fa6d3f60c (patch)
treeb586b3d59b23b52451cdc1b5656fb31c686f6c34
parent736c1e6546bd489f747d477bcb9f20e0f7a59be2 (diff)
Remove debug print statements.
-rw-r--r--src/main.rs5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs
index ef75d9e..5b02f1e 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -17,7 +17,6 @@ fn process_cgi(filename: String) -> String {
let vars1 = vars + 1;
query = &filename[vars1..];
script = &filename[..vars];
- println!("{} {}", query, script);
} else {
query = "";
script = &filename;
@@ -138,11 +137,9 @@ fn get_page(filename: String) -> String {
if checks == true && index == false {
if path.contains(".") != true && path.contains(".cgi?") != true {
let result = generate_index(filename);
- println!("balls");
return result.to_string();
} else if path.contains(".cgi?") {
let result = process_cgi(filename);
- println!("quack");
return result.to_string();
}
}
@@ -155,11 +152,9 @@ fn get_page(filename: String) -> String {
return result.to_string();
} else if filename.contains(".cgi") {
let result = process_cgi(filename);
- println!("cheese");
return result.to_string();
} else {
let result = fs::read_to_string(filename);
- println!("e");
match result {
Ok(i) => i.to_string(),
Err(_e) => "<!DOCTYPE HTML><html><body><h1>403 Forbidden</h1><p>The resource you are trying to access cannot be read by the server.</p></body></html>".to_string(),