zekro-archive / zekroBot2

Rework of the original zekroBot
MIT License
8 stars 2 forks source link

Crash when gif command does not find any results #49

Closed zekroTJA closed 6 years ago

zekroTJA commented 6 years ago

Submitted by

If someone else without github account submitted the bug to you Delete this if you are the bug submiter

Issue Type

Description

If the gif search does not return any results, the crash below will cause.

Logs & Screenshots

TIME:      04/16/2018 - 10:16:56
TYPE:      TypeError
MESSAGE:   Cannot read property 'url' of undefined

STACK TRACE:

TypeError: Cannot read property 'url' of undefined
    at IncomingMessage.res.on (/Programs/discordBots/zekroBot2/src/commands/gif.js:48:73)
    at IncomingMessage.emit (events.js:165:20)
    at endReadableNT (_stream_readable.js:1101:12)
    at process._tickCallback (internal/process/next_tick.js:152:19)
zekroTJA commented 6 years ago

Should be fixed with 1095731a038ee2a1c3faae58609f1540bb747c30 Testing in progress.