rewrote singleton to enum where applicable

This commit is contained in:
ingmargoudt 2017-03-14 16:31:57 +01:00
parent 3b62489ef5
commit 234cfe9519
872 changed files with 1796 additions and 2135 deletions

View file

@ -80,8 +80,8 @@ public final class GmailClient {
Message message = new Message();
message.setRaw(Base64.encodeBase64URLSafeString(baos.toByteArray()));
gmail.users().messages().send(ConfigSettings.getInstance().getGoogleAccount()
+ (ConfigSettings.getInstance().getGoogleAccount().endsWith("@gmail.com") ? "" : "@gmail.com"), message).execute();
gmail.users().messages().send(ConfigSettings.instance.getGoogleAccount()
+ (ConfigSettings.instance.getGoogleAccount().endsWith("@gmail.com") ? "" : "@gmail.com"), message).execute();
return true;
} catch (MessagingException | IOException ex) {
logger.error("Error sending message", ex);