@@ -5,7 +5,7 @@ use std::fmt::{Debug, Formatter};
55use std:: ops:: { Add } ;
66use std:: sync:: Arc ;
77use std:: time:: UNIX_EPOCH ;
8-
8+ use tracing :: instrument ;
99use doh_common:: error:: Error ;
1010
1111use crate :: provider:: DnsReply ;
@@ -138,6 +138,7 @@ impl DatabaseService {
138138 } ) . await . map_err ( |e| e. into ( ) )
139139 }
140140
141+ #[ instrument( skip( self ) ) ]
141142 pub async fn create_host_blocked ( & self , host : & str ) -> Result < bool , Error > {
142143
143144 let host_clone = host. to_lowercase ( ) ;
@@ -152,6 +153,7 @@ impl DatabaseService {
152153 } ) . await . map_err ( |e| e. into ( ) )
153154 }
154155
156+ #[ instrument( skip( self ) ) ]
155157 pub async fn delete_host_blocked ( & self , host : & str ) -> Result < bool , Error > {
156158
157159 let host_clone = host. to_lowercase ( ) ;
@@ -193,7 +195,7 @@ impl DatabaseService {
193195
194196 let offset = page * 10 ;
195197 let mut statement = connection. prepare (
196- "SELECT process_name, dns_name, created FROM audit_dns_query ORDER BY id DESC LIMIT 10 OFFSET ?"
198+ "SELECT process_name, dns_name, strftime('%s', ' created') FROM audit_dns_query ORDER BY id DESC LIMIT 10 OFFSET ?"
197199 ) ?;
198200
199201 let mut rows = statement. query ( params ! [ offset] ) ?;
0 commit comments