Skip to content

Commit 7e192eb

Browse files
authored
Merge branch 'main' into support-async-viewcontext
2 parents 9b8194f + 752967e commit 7e192eb

3 files changed

Lines changed: 4 additions & 4 deletions

File tree

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@defra/forms-engine-plugin",
3-
"version": "0.1.12",
3+
"version": "0.1.13",
44
"description": "Defra forms engine",
55
"type": "module",
66
"files": [

src/server/plugins/nunjucks/context.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ export async function context(request) {
4343
throw Error('Missing baseLayoutPath in plugin.options.nunjucks')
4444
}
4545

46-
if ('viewContext' in pluginStorage) {
46+
if (typeof pluginStorage.viewContext === 'function') {
4747
consumerViewContext = await pluginStorage.viewContext(request)
4848
}
4949

0 commit comments

Comments
 (0)