Commit 33d729a4 authored by Anton's avatar Anton

Update from master

parents 1dc9befb 23b48eab
Pipeline #31015 passed with stage
in 1 minute and 47 seconds
......@@ -21,7 +21,7 @@ jobs:
release_dev:
working_directory: /app
docker:
- image: docker:stable-git
- image: docker:18-git
steps:
- checkout
- run: *pull-submodules
......@@ -42,7 +42,7 @@ jobs:
release_production:
working_directory: /app
docker:
- image: docker:stable-git
- image: docker:18-git
steps:
- checkout
- run: *pull-submodules
......@@ -60,7 +60,7 @@ jobs:
release_staging:
working_directory: /app
docker:
- image: docker:stable-git
- image: docker:18-git
steps:
- checkout
- run: *pull-submodules
......
......@@ -89,6 +89,6 @@ The application listens on port `3030`.
## License
:copyright: 2019 Mainz University of Applied Sciences (Motion Bank Project) –
:copyright: 2020 Mainz University of Applied Sciences (Motion Bank Project) –
Released under the [MIT](https://github.com/motionbank-js/systems-frontend/blob/master/LICENSE) license
import { BASE_URI } from 'mbjs-data-models/src/constants'
// import { BASE_URI } from 'mbjs-data-models/src/constants'
import { Assert } from 'mbjs-utils'
const metadata = {
......@@ -15,7 +15,7 @@ const metadata = {
actions: {
async get (context, payload) {
Assert.ok(typeof payload === 'string' || typeof payload.body.source.id === 'string',
'Metadata request payload must be UUID string or annotation object')
'Metadata request payload must be ID string or annotation object')
if (typeof payload === 'string') {
payload = await context.dispatch('annotations/get', payload, { root: true })
}
......@@ -52,7 +52,7 @@ const metadata = {
},
async getLocal (context, payload) {
Assert.ok(typeof payload === 'string' || typeof payload.body.source.id === 'string',
'Metadata request payload must be UUID string or annotation object')
'Metadata request payload must be ID string or annotation object')
if (typeof payload === 'string') {
payload = await context.dispatch('annotations/get', payload, { root: true })
......@@ -64,7 +64,7 @@ const metadata = {
},
async fetchTitle (context, [metadata, payload]) {
const titleQuery = {
'target.id': typeof payload === 'string' ? `${BASE_URI}/annotations/${payload}` : payload.id,
'target.id': typeof payload === 'string' ? payload : payload.id,
'body.purpose': 'describing',
'body.type': 'TextualBody'
}
......
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