update get-page and get-all-pages content hooks

This commit is contained in:
Greg Hoskin
2021-04-09 16:51:35 -06:00
parent abd86329d5
commit 644f196c97
5 changed files with 18 additions and 24 deletions

View File

@@ -3,11 +3,10 @@ import { swellConfig } from '../../index'
const fetchSwellApi = async (
query: string,
method: string,
variables: object | string
variables: [] = []
) => {
const { swell } = swellConfig
const res = await swell[query][method](variables)
return res
return await swell[query][method](...variables)
}
export default fetchSwellApi