File tree Expand file tree Collapse file tree 4 files changed +15
-5
lines changed
src/routes/(console)/organization-[organization]/domains Expand file tree Collapse file tree 4 files changed +15
-5
lines changed Original file line number Diff line number Diff line change 9393 {#if ! isDomainVerified (domain )}
9494 <Badge
9595 variant =" secondary"
96- type =" warning "
96+ type =" error "
9797 content =" Not verified"
9898 size =" s" />
9999 {/if }
Original file line number Diff line number Diff line change 11<script lang =" ts" >
22 import { base } from ' $app/paths' ;
33 import { page } from ' $app/state' ;
4+ import { goto } from ' $app/navigation' ;
45 import { Button , Form } from ' $lib/elements/forms' ;
56 import { InputDomain } from ' $lib/elements/forms/index.js' ;
67 import { Wizard } from ' $lib/layout' ;
2324 teamId: page .params .organization ,
2425 domain: domainName .toLocaleLowerCase ()
2526 });
26- invalidate (Dependencies .DOMAINS );
27+
28+ await invalidate (Dependencies .DOMAINS );
29+ const verified = domain .nameservers .toLowerCase () === ' appwrite' ;
30+ if (verified ) {
31+ addNotification ({
32+ type: ' success' ,
33+ message: ' Domain verified successfully'
34+ });
35+ await goto (backPage );
36+ }
2737 } catch (error ) {
2838 addNotification ({
2939 type: ' error' ,
Original file line number Diff line number Diff line change 3939 if (verified ) {
4040 addNotification ({
4141 type: ' success' ,
42- message: ' Domain verified'
42+ message: ' Domain verified successfully '
4343 });
4444
4545 await goto (routeBase );
7676 {#if verified === false }
7777 <Badge
7878 variant =" secondary"
79- type =" warning "
79+ type =" error "
8080 size =" xs"
8181 content =" Verification failed" />
8282 {:else if verified === true }
Original file line number Diff line number Diff line change 3636 show = false ;
3737 addNotification ({
3838 type: ' success' ,
39- message: ` ${ selectedDomain . domain } has been verified`
39+ message: ' Domain verified successfully '
4040 });
4141 } else {
4242 error =
You can’t perform that action at this time.
0 commit comments