|
|
@ -10,7 +10,7 @@ use crate::try_log;
|
|
|
|
|
|
|
|
|
|
|
|
impl Db {
|
|
|
|
impl Db {
|
|
|
|
/// Load a player from the database.
|
|
|
|
/// Load a player from the database.
|
|
|
|
pub fn load_player(&self, id: Id) -> RudeResult<Option<Player>> {
|
|
|
|
pub fn _load_player(&self, id: Id) -> RudeResult<Option<Player>> {
|
|
|
|
let mut statement = try_log!(
|
|
|
|
let mut statement = try_log!(
|
|
|
|
self.0
|
|
|
|
self.0
|
|
|
|
.prepare("select id, name, password, created, location from players where id = ?"),
|
|
|
|
.prepare("select id, name, password, created, location from players where id = ?"),
|
|
|
|