diff --git a/index.js b/index.js index b3c3bf12..98bcf61a 100644 --- a/index.js +++ b/index.js @@ -501,7 +501,8 @@ const createClient = (profile, userAgent, opt = {}) => { } = await profile.request({profile, opt}, userAgent, req) const ctx = {profile, opt, common, res} - return res.msgL.map(w => profile.parseWarning(ctx, w)) + return (res.msgL || []) + .map(w => profile.parseWarning(ctx, w)) } const lines = async (query, opt = {}) => {