aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTeddy Wing2018-11-03 20:05:52 +0100
committerTeddy Wing2018-11-03 20:05:52 +0100
commitd3ac5363b4f657284dd15ced308abd1c67b6ab9a (patch)
treec657edf37ae53d2e083fcf972bda1bd942793568
parent46664541a1c70839acce594dc9acfe23a15480b9 (diff)
downloadDomeKey-d3ac5363b4f657284dd15ced308abd1c67b6ab9a.tar.bz2
Move `dome_key_logger_init` call to `main()`
Doesn't make sense to have this in the `HeadphoneKey` initialiser. Since it's something that needs to be done near the start of the program, move it into `main()`.
-rw-r--r--DomeKey/HeadphoneKey.m2
-rw-r--r--DomeKey/main.m2
2 files changed, 2 insertions, 2 deletions
diff --git a/DomeKey/HeadphoneKey.m b/DomeKey/HeadphoneKey.m
index 11046e7..aec9598 100644
--- a/DomeKey/HeadphoneKey.m
+++ b/DomeKey/HeadphoneKey.m
@@ -26,8 +26,6 @@ static BOOL _play_audio;
_play_audio = NO;
- // TODO: Think about moving this logger higher up
- dome_key_logger_init();
dome_key_state_load_map_group(_state);
_mikeys = [DDHidAppleMikey allMikeys];
diff --git a/DomeKey/main.m b/DomeKey/main.m
index 360129a..0b33a55 100644
--- a/DomeKey/main.m
+++ b/DomeKey/main.m
@@ -27,6 +27,8 @@ int main(int argc, const char * argv[]) {
config = dome_key_parse_args(argv, argc, config);
+ dome_key_logger_init();
+
if (config->args.license) {
[LicenseHandler addLicense:[NSString
stringWithCString:config->args.license