Commit bf25bc78 authored by Volker Krause's avatar Volker Krause
Browse files

Set the previous/next journey query capabilities for OTP2

parent 0da7f46b
...@@ -34,7 +34,8 @@ OpenTripPlannerGraphQLBackend::~OpenTripPlannerGraphQLBackend() = default; ...@@ -34,7 +34,8 @@ OpenTripPlannerGraphQLBackend::~OpenTripPlannerGraphQLBackend() = default;
AbstractBackend::Capabilities OpenTripPlannerGraphQLBackend::capabilities() const AbstractBackend::Capabilities OpenTripPlannerGraphQLBackend::capabilities() const
{ {
return m_endpoint.startsWith(QLatin1String("https://")) ? Secure : NoCapability; return (m_endpoint.startsWith(QLatin1String("https://")) ? Secure : NoCapability)
| (m_apiVersion == QLatin1String("otp2") ? (CanQueryNextJourney | CanQueryPreviousJourney) : NoCapability);
} }
bool OpenTripPlannerGraphQLBackend::needsLocationQuery(const Location &loc, AbstractBackend::QueryType type) const bool OpenTripPlannerGraphQLBackend::needsLocationQuery(const Location &loc, AbstractBackend::QueryType type) const
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment