Closed JakeRoggenbuck closed 1 year ago
Previously both lid and power recall the function each time they are called, this results in a loop and 4 file exist checks each call
Save two calls to get_best_path per daemon refresh.
Save eight calls to path().exists() per daemon refresh.
This is how much time get_best_path (in blue) would take up before for read_lid_state (green).
Previously both lid and power recall the function each time they are called, this results in a loop and 4 file exist checks each call
Save two calls to get_best_path per daemon refresh.
Save eight calls to path().exists() per daemon refresh.