diff --git a/phpmon/Common/Core/Constants.swift b/phpmon/Common/Core/Constants.swift index 02311d0..a08b8ed 100644 --- a/phpmon/Common/Core/Constants.swift +++ b/phpmon/Common/Core/Constants.swift @@ -50,11 +50,9 @@ class Constants { // dev release. In this case, that means that the version below is detected. "8.2" ] - - /** - The URL that people can visit if they wish to help support the project. - */ + static let DonationUrlDirect = URL(string: "https://nicoverbruggen.be/sponsor#pay-now")! static let DonationUrl = URL(string: "https://nicoverbruggen.be/sponsor")! + static let FrequentlyAskedQuestionsUrl = URL(string: "https://github.com/nicoverbruggen/phpmon#%EF%B8%8F-faq--troubleshooting")! } diff --git a/phpmon/Domain/Menu/MainMenu+FixMyValet.swift b/phpmon/Domain/Menu/MainMenu+FixMyValet.swift index b046d99..9745ade 100644 --- a/phpmon/Domain/Menu/MainMenu+FixMyValet.swift +++ b/phpmon/Domain/Menu/MainMenu+FixMyValet.swift @@ -7,6 +7,7 @@ // import Foundation +import AppKit extension MainMenu { @@ -70,11 +71,14 @@ extension MainMenu { subtitle: "alert.fix_my_valet_done.subtitle".localized, description: "alert.fix_my_valet_done.desc".localized ) - .withPrimary(text: "alert.fix_my_valet_done.stay".localized(PhpEnv.brewPhpVersion)) - .withSecondary(text: "alert.fix_my_valet_done.switch_back".localized(version), action: { alert in + .withPrimary(text: "alert.fix_my_valet_done.switch_back".localized(version), action: { alert in alert.close(with: .alertSecondButtonReturn) MainMenu.shared.switchToPhpVersion(version) }) + .withSecondary(text: "alert.fix_my_valet_done.stay".localized(PhpEnv.brewPhpVersion)) + .withTertiary(text: "", action: { alert in + NSWorkspace.shared.open(Constants.FrequentlyAskedQuestionsUrl) + }) .show() }