Skip to content

🐛 Handle config without pluginOptions defined #2

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 15, 2019

Conversation

iamphi
Copy link
Contributor

@iamphi iamphi commented Mar 13, 2019

No description provided.

deraw
deraw previously approved these changes Mar 13, 2019
index.js Outdated
@@ -1,6 +1,7 @@
var proxy = require('http-proxy-middleware');

module.exports = (api, options) => {
if (options.pluginOptions === undefined) return;
const opts = options.pluginOptions.proxy;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Account for null as well?
const opts = options.pluginOptions && options.pluginOptions.proxy;

@deraw deraw self-assigned this Mar 13, 2019
@deraw deraw added the bug Something isn't working label Mar 13, 2019
@deraw deraw merged commit 40b2d52 into deraw:master Mar 15, 2019
@deraw
Copy link
Owner

deraw commented Mar 15, 2019

@iamphi & @romansp v2.2.1 is out!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants