From bb3d9327bd6b443df035259d03f1edbd194d877d Mon Sep 17 00:00:00 2001 From: "Christian P. MOMON" Date: Sat, 24 Aug 2013 15:00:50 +0200 Subject: [PATCH] Fix null case. --- .../xidyn/presenters/URLPresenter.java | 22 ++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/src/fr/devinsy/xidyn/presenters/URLPresenter.java b/src/fr/devinsy/xidyn/presenters/URLPresenter.java index 458b04f..105ff7d 100644 --- a/src/fr/devinsy/xidyn/presenters/URLPresenter.java +++ b/src/fr/devinsy/xidyn/presenters/URLPresenter.java @@ -94,7 +94,27 @@ public class URLPresenter extends StringPresenter { String result; - result = this.source.toString(); + if (this.source == null) + { + result = null; + } + else + { + result = this.source.toString(); + } + + // + return (result); + } + + /** + * + */ + public URL getURL() + { + URL result; + + result = this.source; // return (result);