forked from cadey/maj
more words
This commit is contained in:
parent
687bece5be
commit
d10611ac35
|
@ -1,13 +1,13 @@
|
||||||
use async_std::task;
|
use async_std::task;
|
||||||
use maj::{
|
use maj::{
|
||||||
gemini::Builder,
|
gemini::{Builder, Node},
|
||||||
route, seg,
|
route, seg,
|
||||||
server::{Error, Handler as MajHandler, Request},
|
server::{Error, Handler as MajHandler, Request},
|
||||||
split, Response,
|
split, Response,
|
||||||
};
|
};
|
||||||
use percent_encoding::percent_decode_str;
|
use percent_encoding::percent_decode_str;
|
||||||
use rustls::internal::pemfile::{certs, rsa_private_keys};
|
|
||||||
use rustls::{
|
use rustls::{
|
||||||
|
internal::pemfile::{certs, rsa_private_keys},
|
||||||
AllowAnyAnonymousOrAuthenticatedClient, Certificate, PrivateKey, RootCertStore, ServerConfig,
|
AllowAnyAnonymousOrAuthenticatedClient, Certificate, PrivateKey, RootCertStore, ServerConfig,
|
||||||
};
|
};
|
||||||
use std::fs::File;
|
use std::fs::File;
|
||||||
|
@ -121,7 +121,7 @@ async fn input(req: Request) -> Result<Response, Error> {
|
||||||
match req.url.query() {
|
match req.url.query() {
|
||||||
None => Ok(Response::input("test")),
|
None => Ok(Response::input("test")),
|
||||||
Some(q) => Ok({
|
Some(q) => Ok({
|
||||||
use maj::gemini::Node::{self, *};
|
use Node::*;
|
||||||
let result = vec![
|
let result = vec![
|
||||||
Heading {
|
Heading {
|
||||||
level: 1,
|
level: 1,
|
||||||
|
@ -139,7 +139,7 @@ async fn input(req: Request) -> Result<Response, Error> {
|
||||||
|
|
||||||
async fn user(name: String) -> Result<Response, Error> {
|
async fn user(name: String) -> Result<Response, Error> {
|
||||||
Ok(Response::render({
|
Ok(Response::render({
|
||||||
use maj::gemini::Node::{self, *};
|
use Node::*;
|
||||||
|
|
||||||
vec![
|
vec![
|
||||||
Heading {
|
Heading {
|
||||||
|
|
Loading…
Reference in New Issue