Skip to content

post-redirect? not working or Preflight response is not successful #318

Open
@zendevil

Description

@zendevil

I have the following code:

defresource handle-sign-in [redirect-uri]
  :available-media-types ["application/json"]
  :allowed-methods [:post]
  :post! (prn "welcome to post")
  :post-redirect? (fn [_] ;;(ring-response
                           {:location redirect-uri}
                           ;;)
                    )
  )

When I send the request, I get the errors Preflight response is not successful and XMLHttpRequest cannot load [authorize-uri] due to access control checks.
When I wrap the redirect location map around ring-response, however, I don't get the errors but neither do I get the redirect. What am I doing wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions