Skip to content

Commit

Permalink
Merge pull request #12 from MarcoFalke/update-min-version
Browse files Browse the repository at this point in the history
Normalize user name and bump version
  • Loading branch information
Rillke committed Jun 29, 2015
2 parents 7aab035 + 9511a7a commit 4ca614f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
6 changes: 3 additions & 3 deletions fbot/ft/GlobalReplace.java
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ public class GlobalReplace {
private static final String NAME = "GlobalReplace";
private static final String COMMONS_PAGE = "Commons:" + NAME;
private static final String SIGN_UP = COMMONS_PAGE + "/Sign-in";
private static final byte[] VERSION_NUM = new byte[] { 0, 5, 0 };// {X},{fix},{minor}
private static final byte[] VERSION_NUM = new byte[] { 0, 6, 0 };// {X},{fix},{minor}
private static final String VERSION = "v" + VERSION_NUM[0] + "."
+ VERSION_NUM[1] + "." + VERSION_NUM[2];
private static final String TITLE = "GlobalReplace " + VERSION;
Expand Down Expand Up @@ -135,11 +135,11 @@ private static void signup() {
+ "]]";
if (!text.contains(user)) {
boolean success = wiki.edit(SIGN_UP, text.trim() + "\n#" + user
+ " {{subst:#time:d F Y}}", "Signing up via " + TITLE);
+ ", {{subst:#time:d F Y}}", "Signing up via " + TITLE);
if (!success) {
JOptionPane.showConfirmDialog(null,
"You are not allowed to use this tool; Please request permission at "
+ SIGN_UP + ". Program exiting",
+ SIGN_UP + ".\nProgram exiting",
"Missing permission", JOptionPane.OK_CANCEL_OPTION);
System.exit(0);
}
Expand Down
3 changes: 3 additions & 0 deletions fbot/lib/core/Wiki.java
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ public Wiki(String user, String px) {
}

public Wiki(String user, String px, String domain) {
// first char is upper case usually
user = Character.toString(user.charAt(0)).toUpperCase()
+ user.substring(1);
this.settings = new Credentials(user, px);
this.settings.setTo(domain);
}
Expand Down

0 comments on commit 4ca614f

Please sign in to comment.