File tree Expand file tree Collapse file tree 2 files changed +14
-4
lines changed
Expand file tree Collapse file tree 2 files changed +14
-4
lines changed Original file line number Diff line number Diff line change @@ -185,9 +185,14 @@ module.exports = function(reqctx) {
185185 try {
186186 // `require` will raise an error if this className isn't found:
187187 component = fromCtx ( className )
188- } catch ( err ) {
188+ } catch ( firstErr ) {
189189 // fallback to global:
190- component = fromGlobal ( className )
190+ try {
191+ component = fromGlobal ( className )
192+ } catch ( secondErr ) {
193+ console . error ( firstErr )
194+ console . error ( secondErr )
195+ }
191196 }
192197 return component
193198 }
Original file line number Diff line number Diff line change @@ -185,9 +185,14 @@ module.exports = function(reqctx) {
185185 try {
186186 // `require` will raise an error if this className isn't found:
187187 component = fromCtx ( className )
188- } catch ( err ) {
188+ } catch ( firstErr ) {
189189 // fallback to global:
190- component = fromGlobal ( className )
190+ try {
191+ component = fromGlobal ( className )
192+ } catch ( secondErr ) {
193+ console . error ( firstErr )
194+ console . error ( secondErr )
195+ }
191196 }
192197 return component
193198 }
You can’t perform that action at this time.
0 commit comments