mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Make GithubSettingsConfigurable pass ConfigurablesModifiedTest
This commit is contained in:
@@ -70,27 +70,30 @@ public class GithubSettings implements PersistentStateComponent<Element> {
|
||||
}
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public String getLogin() {
|
||||
return myLogin;
|
||||
return myLogin != null ? myLogin : "";
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public String getPassword() {
|
||||
return myPassword;
|
||||
return myPassword != null ? myPassword : "";
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public String getClonePath() {
|
||||
return myClonePath != null ? myClonePath : "";
|
||||
}
|
||||
|
||||
public void setLogin(final String login) {
|
||||
myLogin = login;
|
||||
myLogin = login != null ? login : "";
|
||||
}
|
||||
|
||||
public void setPassword(final String password) {
|
||||
myPassword = password;
|
||||
myPassword = password != null ? password : "";
|
||||
}
|
||||
|
||||
public String getClonePath() {
|
||||
return myClonePath;
|
||||
}
|
||||
|
||||
public void setClonePath(String clonePath) {
|
||||
myClonePath = clonePath;
|
||||
public void setClonePath(final String clonePath) {
|
||||
myClonePath = clonePath != null ? clonePath : "";
|
||||
}
|
||||
}
|
||||
@@ -3,7 +3,6 @@ package org.jetbrains.plugins.github.ui;
|
||||
import com.intellij.openapi.options.ConfigurationException;
|
||||
import com.intellij.openapi.options.SearchableConfigurable;
|
||||
import com.intellij.openapi.util.IconLoader;
|
||||
import com.intellij.openapi.util.text.StringUtil;
|
||||
import org.jetbrains.plugins.github.GithubSettings;
|
||||
|
||||
import javax.swing.*;
|
||||
@@ -41,8 +40,8 @@ public class GitHubSettingsConfigurable implements SearchableConfigurable {
|
||||
}
|
||||
|
||||
public boolean isModified() {
|
||||
return mySettingsPane == null || !StringUtil.equals(mySettings.getLogin(), mySettingsPane.getLogin()) ||
|
||||
!StringUtil.equals(mySettings.getPassword(), mySettingsPane.getPassword());
|
||||
return mySettingsPane == null || !mySettings.getLogin().equals(mySettingsPane.getLogin()) ||
|
||||
!mySettings.getPassword().equals(mySettingsPane.getPassword());
|
||||
}
|
||||
|
||||
public void apply() throws ConfigurationException {
|
||||
|
||||
Reference in New Issue
Block a user