Changes to handlesubmit
This commit is contained in:
		
							parent
							
								
									e7e79ced13
								
							
						
					
					
						commit
						b999e47f94
					
				
					 1 changed files with 4 additions and 3 deletions
				
			
		|  | @ -15,9 +15,10 @@ function LoginPage(props: { | ||||||
|    and if so, redirect to correct page */ |    and if so, redirect to correct page */ | ||||||
|   function handleSubmit(event: FormEvent<HTMLFormElement>): void { |   function handleSubmit(event: FormEvent<HTMLFormElement>): void { | ||||||
|     event.preventDefault(); |     event.preventDefault(); | ||||||
|     props.setAuthority((prevAuth) => { |     LoginCheck({ | ||||||
|       prevAuth = LoginCheck({ username: username, password: password }); |       username: username, | ||||||
|       return prevAuth; |       password: password, | ||||||
|  |       setAuthority: props.setAuthority, | ||||||
|     }); |     }); | ||||||
|   } |   } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Peter KW
						Peter KW