@read_auths += ApiClientAuthorization
.includes(:user)
.where('api_token IN (?) AND
- (expires_at IS NULL OR expires_at > CURRENT_TIMESTAMP AT TIME ZONE ?)',
- secrets, 'UTC')
+ (expires_at IS NULL OR expires_at > CURRENT_TIMESTAMP)',
+ secrets)
.to_a
end
@read_auths.select! { |auth| auth.scopes_allow_request? request }