File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed
Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -35,8 +35,8 @@ pub struct Point<'a> {
3535
3636impl < ' a > Point < ' a > {
3737 /// Create a new point
38- pub fn new ( measurement : & str ) -> Point {
39- Point {
38+ pub fn new ( measurement : & ' _ str ) -> Self {
39+ Self {
4040 measurement : String :: from ( measurement) ,
4141 tags : HashMap :: new ( ) ,
4242 fields : HashMap :: new ( ) ,
Original file line number Diff line number Diff line change @@ -33,6 +33,7 @@ fn create_and_delete_measurement() {
3333
3434 tokio:: spawn ( client. write_point ( point, Some ( Precision :: Seconds ) , None ) )
3535 . await
36+ . unwrap ( )
3637 . unwrap ( ) ;
3738
3839 client. drop_measurement ( "temporary" ) . await . unwrap ( ) ;
@@ -62,6 +63,7 @@ fn use_points() {
6263
6364 tokio:: spawn ( client. write_points ( points, Some ( Precision :: Seconds ) , None ) )
6465 . await
66+ . unwrap ( )
6567 . unwrap ( ) ;
6668
6769 sleep ( Duration :: from_secs ( 3 ) ) ;
You can’t perform that action at this time.
0 commit comments