Skip to content

Commit

Permalink
more docs changes
Browse files Browse the repository at this point in the history
  • Loading branch information
rishabhpoddar committed Apr 9, 2024
1 parent 12662eb commit 541ff91
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 36 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ function verifySession(options?: VerifySessionOptions) {
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1164,7 +1164,7 @@ func VerifySession(options *sessmodels.VerifySessionOptions, otherHandler http.H
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1248,7 +1248,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down Expand Up @@ -1306,7 +1306,7 @@ async function verifySession(accessToken: string, antiCsrfToken?: string, option
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}
}
throw err;
Expand Down Expand Up @@ -1357,7 +1357,7 @@ func VerifySession(accessToken string, antiCsrfToken *string, options *sessmodel
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
} else {
// TODO: send a 500 error to the frontend
}
Expand Down Expand Up @@ -1437,7 +1437,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ function verifySession(options?: VerifySessionOptions) {
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1164,7 +1164,7 @@ func VerifySession(options *sessmodels.VerifySessionOptions, otherHandler http.H
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1248,7 +1248,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down Expand Up @@ -1306,7 +1306,7 @@ async function verifySession(accessToken: string, antiCsrfToken?: string, option
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}
}
throw err;
Expand Down Expand Up @@ -1357,7 +1357,7 @@ func VerifySession(accessToken string, antiCsrfToken *string, options *sessmodel
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
} else {
// TODO: send a 500 error to the frontend
}
Expand Down Expand Up @@ -1437,7 +1437,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ function verifySession(options?: VerifySessionOptions) {
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1164,7 +1164,7 @@ func VerifySession(options *sessmodels.VerifySessionOptions, otherHandler http.H
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1248,7 +1248,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down Expand Up @@ -1306,7 +1306,7 @@ async function verifySession(accessToken: string, antiCsrfToken?: string, option
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}
}
throw err;
Expand Down Expand Up @@ -1357,7 +1357,7 @@ func VerifySession(accessToken string, antiCsrfToken *string, options *sessmodel
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
} else {
// TODO: send a 500 error to the frontend
}
Expand Down Expand Up @@ -1437,7 +1437,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ function verifySession(options?: VerifySessionOptions) {
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1164,7 +1164,7 @@ func VerifySession(options *sessmodels.VerifySessionOptions, otherHandler http.H
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1248,7 +1248,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down Expand Up @@ -1306,7 +1306,7 @@ async function verifySession(accessToken: string, antiCsrfToken?: string, option
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}
}
throw err;
Expand Down Expand Up @@ -1357,7 +1357,7 @@ func VerifySession(accessToken string, antiCsrfToken *string, options *sessmodel
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
} else {
// TODO: send a 500 error to the frontend
}
Expand Down Expand Up @@ -1437,7 +1437,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ function verifySession(options?: VerifySessionOptions) {
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1164,7 +1164,7 @@ func VerifySession(options *sessmodels.VerifySessionOptions, otherHandler http.H
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1248,7 +1248,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down Expand Up @@ -1306,7 +1306,7 @@ async function verifySession(accessToken: string, antiCsrfToken?: string, option
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}
}
throw err;
Expand Down Expand Up @@ -1357,7 +1357,7 @@ func VerifySession(accessToken string, antiCsrfToken *string, options *sessmodel
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
} else {
// TODO: send a 500 error to the frontend
}
Expand Down Expand Up @@ -1437,7 +1437,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1113,7 +1113,7 @@ function verifySession(options?: VerifySessionOptions) {
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1164,7 +1164,7 @@ func VerifySession(options *sessmodels.VerifySessionOptions, otherHandler http.H
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}

// OR you can use this errorHandler which will
Expand Down Expand Up @@ -1248,7 +1248,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down Expand Up @@ -1306,7 +1306,7 @@ async function verifySession(accessToken: string, antiCsrfToken?: string, option
// Or you can call the errorHandler middleware as shown below
} else if (err.type === Session.Error.INVALID_CLAIMS) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
}
}
throw err;
Expand Down Expand Up @@ -1357,7 +1357,7 @@ func VerifySession(accessToken string, antiCsrfToken *string, options *sessmodel
// Or you can call the errorHandler middleware as shown below
} else if defaultErrors.As(err, &errors.InvalidClaimError{}) {
// The user is missing some required claim.
// You can pass the missing claims to the frontend and handle it there
// You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
} else {
// TODO: send a 500 error to the frontend
}
Expand Down Expand Up @@ -1437,7 +1437,7 @@ def verify_session(
pass
if isinstance(e, InvalidClaimsError):
# The user is missing some required claim.
# You can pass the missing claims to the frontend and handle it there
# You can pass the missing claims to the frontend and handle it there. Send a 403 to the frontend.
pass

# OR you can raise this error which will
Expand Down

0 comments on commit 541ff91

Please sign in to comment.