Fix pacman search output if there are no results

This commit is contained in:
kageru 2019-10-31 12:06:06 +01:00
parent 655f4cf24b
commit af1891f3b9
Signed by: kageru
GPG Key ID: 8282A2BEA4ADA3D2

View File

@ -14,7 +14,7 @@ pub fn query_pacman(ctx: Context, msg: Message, args: Vec<&str>) {
|_e| EMPTY_RESULT,
);
// this is 1 for most packages and 2 if there’s a second version in testing
if response.results.is_empty() {
if response.results.len() != 0 {
respond_with_results(msg.channel_id, &response.results, &ctx);
return;
}