# HG changeset patch # User Kim Alvefur # Date 1458572774 -3600 # Node ID c61fadb9d4fa017fa76ca185bbee013ea5b93db9 # Parent 1dfd28db10bd651329ec2cbd6238116a271d8ae6 clix.roster: Print error resplies diff -r 1dfd28db10bd -r c61fadb9d4fa clix/roster.lua --- a/clix/roster.lua Mon Sep 08 12:20:24 2014 +0200 +++ b/clix/roster.lua Mon Mar 21 16:06:14 2016 +0100 @@ -1,6 +1,14 @@ short_opts.i = "interactive"; local split_jid = require "util.jid".split; -local function printor(str) return function() print(str) end end +local function printor(str) + return function(ok, err) + if ok then + print(str) + else + print(err:get_error()); + end + end +end return function (opts, arg) if opts.short_help then