mirror of
https://github.com/mas-cli/mas
synced 2024-11-25 04:50:24 +00:00
parent
bfed0a7605
commit
4660b4505b
1 changed files with 6 additions and 0 deletions
|
@ -29,6 +29,12 @@ public struct PurchaseCommand: CommandProtocol {
|
||||||
|
|
||||||
/// Runs the command.
|
/// Runs the command.
|
||||||
public func run(_ options: Options) -> Result<Void, MASError> {
|
public func run(_ options: Options) -> Result<Void, MASError> {
|
||||||
|
if #available(macOS 10.15, *) {
|
||||||
|
// Purchases are no longer possible as of Catalina.
|
||||||
|
// https://github.com/mas-cli/mas/issues/289
|
||||||
|
return .failure(.notSupported)
|
||||||
|
}
|
||||||
|
|
||||||
// Try to download applications with given identifiers and collect results
|
// Try to download applications with given identifiers and collect results
|
||||||
let appIds = options.appIds.filter { appId in
|
let appIds = options.appIds.filter { appId in
|
||||||
if let product = appLibrary.installedApp(forId: appId) {
|
if let product = appLibrary.installedApp(forId: appId) {
|
||||||
|
|
Loading…
Reference in a new issue