From 99023f94871e1f9bad5ee5f5db0ff041a02e9ed5 Mon Sep 17 00:00:00 2001 From: Jesse Plamondon-Willard Date: Sun, 4 Mar 2018 18:46:05 -0500 Subject: add support for mapping non-semantic remote mod versions --- src/SMAPI.Common/Models/ModSeachModel.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/SMAPI.Common') diff --git a/src/SMAPI.Common/Models/ModSeachModel.cs b/src/SMAPI.Common/Models/ModSeachModel.cs index 13b05d2d..3c33d0b6 100644 --- a/src/SMAPI.Common/Models/ModSeachModel.cs +++ b/src/SMAPI.Common/Models/ModSeachModel.cs @@ -12,6 +12,9 @@ namespace StardewModdingAPI.Common.Models /// The namespaced mod keys to search. public string[] ModKeys { get; set; } + /// Whether to allow non-semantic versions, instead of returning an error for those. + public bool AllowInvalidVersions { get; set; } + /********* ** Public methods @@ -24,9 +27,11 @@ namespace StardewModdingAPI.Common.Models /// Construct an instance. /// The namespaced mod keys to search. - public ModSearchModel(IEnumerable modKeys) + /// Whether to allow non-semantic versions, instead of returning an error for those. + public ModSearchModel(IEnumerable modKeys, bool allowInvalidVersions) { this.ModKeys = modKeys.ToArray(); + this.AllowInvalidVersions = allowInvalidVersions; } } } -- cgit