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

Remember openkeychain key #24

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

DeX77
Copy link
Contributor

@DeX77 DeX77 commented Jan 26, 2018

Initial Work for #19

What do you think @LittleFox94 ?

Copy link
Member

@LittleFox94 LittleFox94 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently mostly some code style things

@@ -71,12 +71,12 @@ public void close() {
}
}

public void doActionOnServerWithFeedback(String action, String server, String keyAPG) {
String ret = doActionOnServer(action, server, keyAPG);
public void doActionOnServerWithFeedback(String action, String server, String keyAPG, String openPGPKey) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please rename to openPGPKeyID everywhere

This way its is clearer what that variable is ^^

@@ -12,15 +12,19 @@
String _name;
String _url;
String _apgKey;
String _openpgpgKey;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pgpg? Looks like a nice combination of PGP and GPG, but please only use one ^^
I would prefer PGP

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you reuse apgKey? (did we have that question before :O )

@@ -59,8 +83,8 @@ public static Server deserialize(String serialized) {
return new Server(parts[0], parts[1]);
}

if (parts.length == 3) {
return new Server(parts[0], parts[1], parts[2]);
if (parts.length == 5) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do not change things in this function. It is only here to support config loading for configs generated by older versions of the app

@@ -73,6 +97,10 @@ public JSONObject serializeJSON() {
ret.put("name", _name);
ret.put("url", _url);
ret.put("apgKey", _apgKey);
if (saveKey()) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

use private variables where possible, as function calls are slower in most languages.

@LittleFox94
Copy link
Member

But thank you very much for your changes :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants