Skip to content

Commit

Permalink
Fix optional chaining not supported
Browse files Browse the repository at this point in the history
  • Loading branch information
GuilleAngulo committed Jun 18, 2021
1 parent 849d119 commit 3b4b233
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion plugins/feed.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ module.exports = function feed(nextConfig = {}) {

if (debug) {
const regex = new RegExp(plugin.name);
if (!config.infrastructureLogging?.debug) {
if (config.infrastructureLogging === undefined) {
config.infrastructureLogging = {
debug: [regex],
};
Expand Down
2 changes: 1 addition & 1 deletion plugins/search-index.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ module.exports = function indexSearch(nextConfig = {}) {

if (debug) {
const regex = new RegExp(plugin.name);
if (!config.infrastructureLogging?.debug) {
if (config.infrastructureLogging === undefined) {
config.infrastructureLogging = {
debug: [regex],
};
Expand Down
2 changes: 1 addition & 1 deletion plugins/sitemap.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ module.exports = function sitemap(nextConfig = {}) {

if (debug) {
const regex = new RegExp(plugin.name);
if (!config.infrastructureLogging?.debug) {
if (config.infrastructureLogging === undefined) {
config.infrastructureLogging = {
debug: [regex],
};
Expand Down
2 changes: 1 addition & 1 deletion plugins/socialImages.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ module.exports = function sitemap(nextConfig = {}) {

if (debug) {
const regex = new RegExp(plugin.name);
if (!config.infrastructureLogging?.debug) {
if (config.infrastructureLogging === undefined) {
config.infrastructureLogging = {
debug: [regex],
};
Expand Down

0 comments on commit 3b4b233

Please sign in to comment.