Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show toast on data source error #132

Merged
merged 2 commits into from May 21, 2017

Conversation

Projects
None yet
2 participants
@c-w
Copy link
Contributor

commented May 17, 2017

Fixes #83

Example error displayed when the connection to the data-source failed:

image

@c-w c-w changed the base branch from master to ibex-version-1.0 May 17, 2017

@morsh
Copy link
Contributor

left a comment

Just this small fix, and I can merge this.
Very cool you took this on

private errorToMessage(error: any): string {
const exception = error as Error;
if (exception == null) {
return error;

This comment has been minimized.

Copy link
@morsh

morsh May 18, 2017

Contributor

why not:
return exception;

This comment has been minimized.

Copy link
@c-w

c-w May 18, 2017

Author Contributor

This was actually a misunderstanding on my part how as works in TypeScript. I assumed that it worked like in C# (try a cast and if it's not castable, return null). Fixed in 5961bc7 by using instanceof.

@morsh morsh merged commit 29ec245 into Azure:ibex-version-1.0 May 21, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.