Changeset 10813


Ignore:
Timestamp:
05/07/11 18:48:30 (8 years ago)
Author:
mlg
Message:

Bug correction
due to nullpointerexception when retrieving some informations from the config file

Location:
extensions/jiwigo/trunk/src/main/java/fr/mael/jiwigo
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/jiwigo/trunk/src/main/java/fr/mael/jiwigo/transverse/util/preferences/PreferencesManagement.java

    r10748 r10813  
    121121                Tools.setStringValueDom(document.getDocumentElement(), key, text); 
    122122            } catch (Exception e) { 
    123                 e.printStackTrace(); 
    124123                Element element = document.createElement(key); 
    125124                element.setTextContent(text); 
    126125                document.getDocumentElement().appendChild(element); 
    127  
    128126            } 
    129127            Tools.writeXmlFile(document, getConfigFilePath()); 
  • extensions/jiwigo/trunk/src/main/java/fr/mael/jiwigo/ui/ConnexionDialog.java

    r10811 r10813  
    144144        passwordField = new JPasswordField(pass); 
    145145        checkBoxRetenir = new JCheckBox(Messages.getMessage("connexionDialog_sauvegarder")); 
    146         if (!url.equals("") && !login.equals("") && !pass.equals("")) { 
     146        if ((url != null && login != null && pass != null) 
     147                && (!"".equals(url) && !"".equals(login) && !"".equals(pass))) { 
    147148            checkBoxRetenir.setSelected(true); 
    148149        } 
Note: See TracChangeset for help on using the changeset viewer.