Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong response for conflict on update #152

Open
szymonp-kainos opened this issue Sep 5, 2016 · 1 comment
Open

Wrong response for conflict on update #152

szymonp-kainos opened this issue Sep 5, 2016 · 1 comment

Comments

@szymonp-kainos
Copy link

When doing update with id on conlict:

SELECT fhir_update_resource('{"ifMatch": "4df606bd-3642-4e07-9111-701389381d5e", "resource": {"resourceType":"Patient","id":"4df606bd-3642-4e07-9111-701389381d5e","meta":{"versionId":"4df606bd-3642-4e07-9111-701389381d5e"},"identifier":[{"use":"official","system":"Hospital Number","value":"6b574482-8d13-4186-a6a8-c2bd41e6fb66"}],"name":[{"use":"official","family":["!family!"],"given":["Gordon"]}],"gender":"male","active":"true"}}');

fhirbase returns operation outcome with code 409 instead of conflict as stated in http://hl7.org/fhir/2016May/valueset-issue-type.html

{
    "resourceType": "OperationOutcome",
    "issue": [
        {
            "severity": "error",
            "code": "409",
            "diagnostics": "Newer than [4df606bd-3642-4e07-9111-701389381d5e] version available [de9abe99-d4d2-41ef-a9a3-10c529c63f84]",
            "extension": [
                {
                    "url": "http-status-code",
                    "valueString": "409"
                }
            ]
        }
    ]
}
niquola added a commit that referenced this issue Sep 8, 2016
Fix Bug : #152 - Wrong response for conflict on update
@Andrzej-Pietrzak
Copy link

Thanks, this looks great! This issue can be closed imo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants