#48452: refactor: DRY in App::SetAppLogPath()
Description of Change
This PR has two goals:
-
Reduces duplicated code between the macOS and non-macOS implementations.
App::SetAppLogPath()
is now the same code on all platforms. The only platform-specific code is in a new static private helper function,App::GetDefaultAppLogPath()
. -
Indirectly helps the small series of PRs to reduce
gin_helper
's footprint. One step in this series is to phase out marshallingstd::optional<T>
args throughgin_helper
, and this PR does that forApp::SetAppLogPath()
.
All reviews welcome! CC @codebytere as gin_helper stakeholder & as author of the code being refactored here
Checklist
- PR description included and stakeholders cc'd
-
npm test
passes - PR release notes describe the change in a way relevant to app developers, and are capitalized, punctuated, and past tense.
Release Notes
Notes: none.
Backports
No Backports Requested
This pull request doesn't have any backports requested or created for older release branches.
What are backports?
Backports are copies of changes made to the main branch that are applied to older release branches. They ensure that bug fixes and important changes are available in maintained older versions of Electron.
Semver Impact
Semantic Versioning helps users understand the impact of updates:
- Major (X.y.z): Breaking changes that may require code modifications
- Minor (x.Y.z): New features that maintain backward compatibility
- Patch (x.y.Z): Bug fixes that don't change the API
- None: Changes that don't affect using facing parts of Electron