Skip to content

Commit

Permalink
backend, frontend: minor fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Synar committed Jun 21, 2024
1 parent 8bbcb74 commit d409587
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 0 additions & 2 deletions backend/src/api/map.rs
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,6 @@ async fn check_captcha(state: AppState, response: Option<String>) -> Result<(),
async fn viewer_new_entity(
DbConn(mut conn): DbConn,
State(state): State<AppState>,
MapUserToken(_token): MapUserToken,
Json(request): Json<PublicNewEntityRequest>,
) -> Result<AppJson<PublicNewEntityResponse>, AppError> {
check_captcha(state, request.hcaptcha_token).await?;
Expand Down Expand Up @@ -291,7 +290,6 @@ pub struct NewCommentRequest {
async fn viewer_new_comment(
DbConn(mut conn): DbConn,
State(state): State<AppState>,
MapUserToken(_token): MapUserToken,
Json(request): Json<NewCommentRequest>,
) -> Result<AppJson<PublicComment>, AppError> {
check_captcha(state, request.hcaptcha_token).await?;
Expand Down
4 changes: 2 additions & 2 deletions frontend/components/form/DynamicField.vue
Original file line number Diff line number Diff line change
Expand Up @@ -214,9 +214,9 @@ const isValid = computed(() => {
case 'email':
return validator.isEmail(props.fieldContent as string)
case 'phone':
return false // For now we will avoid making assumptions on phone number formats
return true // For now we will avoid making assumptions on phone number formats
default:
return false
return true
}
})
Expand Down

0 comments on commit d409587

Please sign in to comment.