1 use diesel::{result::Error, *};
2 use lemmy_db_schema::source::secret::Secret;
5 fn init(conn: &PgConnection) -> Result<Secret, Error>;
8 impl Secret_ for Secret {
9 /// Initialize the Secrets from the DB.
10 /// Warning: You should only call this once.
11 fn init(conn: &PgConnection) -> Result<Secret, Error> {
16 fn read_secrets(conn: &PgConnection) -> Result<Secret, Error> {
17 use lemmy_db_schema::schema::secret::dsl::*;
18 secret.first::<Secret>(conn)