fmt: fix alignment of struct init fields (#22025)

This commit is contained in:
yuyi 2024-08-11 14:11:24 +08:00 committed by GitHub
parent 99da5726db
commit c51d30bf53
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
671 changed files with 18817 additions and 18787 deletions

View file

@ -62,9 +62,9 @@ fn make_token(user User) string {
jwt_header := JwtHeader{'HS256', 'JWT'}
jwt_payload := JwtPayload{
sub: '${user.id}'
sub: '${user.id}'
name: '${user.username}'
iat: time.now()
iat: time.now()
}
header := base64.url_encode(json.encode(jwt_header).bytes())

View file

@ -10,7 +10,7 @@ fn (mut app App) service_add_product(product_name string, user_id int) ! {
}
product_model := Product{
name: product_name
name: product_name
user_id: user_id
}

View file

@ -18,7 +18,7 @@ fn (mut app App) service_add_user(username string, password string) ! {
user_model := User{
username: username
password: hashed_password
active: true
active: true
}
mut insert_error := ''