[Kimchi-devel] [PATCH] Add error handling for repo management
Aline Manera
alinefm at linux.vnet.ibm.com
Wed Mar 26 16:37:55 UTC 2014
Reviewed-by: Aline Manera <alinefm at linux.vnet.ibm.com>
On 03/26/2014 01:36 PM, Adam King wrote:
> ListRepo call had no error handler.
>
> Signed-off-by: Adam King <rak at linux.vnet.ibm.com>
> ---
> ui/js/src/kimchi.host.js | 9 +++++++++
> 1 file changed, 9 insertions(+)
>
> diff --git a/ui/js/src/kimchi.host.js b/ui/js/src/kimchi.host.js
> index acd8e8e..e94bad6 100644
> --- a/ui/js/src/kimchi.host.js
> +++ b/ui/js/src/kimchi.host.js
> @@ -176,6 +176,15 @@ kimchi.host_main = function() {
> repositoriesGrid.setData(repositories);
> }
> }
> + },
> + function(error) {
> + var message = error && error['responseJSON'] && error['responseJSON']['reason'];
> +
> + if($.isFunction(gridCallback)) {
> + gridCallback([]);
> + }
> + repositoriesGrid &&
> + repositoriesGrid.showMessage(message || i18n['KCHUPD6008M']);
> });
>
> $('#repositories-grid-remove-button').prop('disabled', true);
More information about the Kimchi-devel
mailing list