SenseNet / sn-redux

A set of redux actions, reducers and redux-ovbservable epics for sensenet
https://www.sensenet.com/
GNU General Public License v2.0
6 stars 3 forks source link

Reducers ids create content success payload doesn't have result property #87

Closed zoltanbedi closed 6 years ago

zoltanbedi commented 6 years ago

In reducers line 210 the action.payload doesn't have a result property.

export const createContent = <T extends IContent = IContent>(parentPath: string, content: T, contentType: string) => ({
    type: 'CREATE_CONTENT',
    // tslint:disable:completed-docs
    async payload(repository: Repository): Promise<IODataResponse<T>> {
        const data = await repository.post<T>({ parentPath, content, contentType })
        return data
    },
})

Create content returns an IODataResponse.

herflis commented 6 years ago

@B3zo0 thanks for the request. It is fixed now in version 4.1.0