File tree 2 files changed +3
-3
lines changed
2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -79,7 +79,7 @@ pub async fn reset_password(username: web::Path<String>) -> Result<impl Responde
79
79
. iter_mut ( )
80
80
. find ( |user| user. username == username)
81
81
{
82
- user. password_hash = hash . clone ( ) ;
82
+ user. password_hash . clone_from ( & hash ) ;
83
83
} else {
84
84
// should be unreachable given state is always consistent
85
85
return Err ( RBACError :: UserDoesNotExist ) ;
Original file line number Diff line number Diff line change @@ -45,14 +45,14 @@ pub async fn run_metadata_migration(config: &Config) -> anyhow::Result<()> {
45
45
}
46
46
47
47
if let Some ( storage_metadata) = storage_metadata {
48
- if let Some ( "v1" ) = dbg ! ( get_version ( & storage_metadata ) ) {
48
+ if get_version ( & storage_metadata ) == Some ( "v1" ) {
49
49
let metadata = metadata_migration:: v1_v2 ( storage_metadata) ;
50
50
put_remote_metadata ( & * object_store, & metadata) . await ?;
51
51
}
52
52
}
53
53
54
54
if let Some ( staging_metadata) = staging_metadata {
55
- if let Some ( "v1" ) = get_version ( & staging_metadata ) {
55
+ if get_version ( & staging_metadata ) == Some ( "v1" ) {
56
56
let metadata = metadata_migration:: v1_v2 ( staging_metadata) ;
57
57
put_staging_metadata ( config, & metadata) ?;
58
58
}
You can’t perform that action at this time.
0 commit comments