Move SQL errors into their own module

This commit is contained in:
Alexander Krotov
2019-11-29 23:06:13 +01:00
committed by Floris Bruynooghe
parent ea8adf39c2
commit 612600278a
9 changed files with 102 additions and 66 deletions

View File

@@ -8,7 +8,6 @@ use crate::aheader::*;
use crate::chat::*;
use crate::constants::*;
use crate::context::Context;
use crate::error::*;
use crate::key::*;
use crate::sql::{self, Sql};
@@ -385,7 +384,7 @@ impl<'a> Peerstate<'a> {
}
}
pub fn save_to_db(&self, sql: &Sql, create: bool) -> Result<()> {
pub fn save_to_db(&self, sql: &Sql, create: bool) -> crate::sql::Result<()> {
if create {
sql::execute(
self.context,