@@ -8,7 +8,7 @@ module Actions
88 class FindPreviousTagAction < Action
99 def self . run ( params )
1010 tag_pattern = params [ :pattern ]
11- exclude_patterns = Array ( params [ :exclude ] )
11+ exclude_patterns = params [ :exclude ] || [ ]
1212
1313 # Make sure we have all the latest tags fetched locally
1414 Actions . sh ( 'git' , 'fetch' , '--tags' , '--force' ) { nil }
@@ -41,7 +41,7 @@ def self.details
4141 reachable from the current commit and that matches a specific naming pattern
4242
4343 e.g. `find_previous_tag(pattern: '12.3.*.*')`, `find_previous_tag(pattern: '12.3-rc-*')`,
44- `find_previous_tag(pattern: 'v*', exclude: '*beta*')`,
44+ `find_previous_tag(pattern: 'v*', exclude: [ '*beta*'] )`,
4545 `find_previous_tag(pattern: 'v*', exclude: ['*alpha*', '*beta*'])`
4646 DETAILS
4747 end
@@ -54,11 +54,10 @@ def self.available_options
5454 default_value : nil ,
5555 type : String ) ,
5656 FastlaneCore ::ConfigItem . new ( key : :exclude ,
57- description : 'One or more _fnmatch_-style patterns of tags to exclude from the search (maps to `git describe --exclude`). ' \
58- 'Can be a single string or an array of strings' ,
57+ description : 'An array of _fnmatch_-style patterns of tags to exclude from the search (maps to `git describe --exclude`)' ,
5958 optional : true ,
6059 default_value : nil ,
61- is_string : false ) ,
60+ type : Array ) ,
6261 ]
6362 end
6463
0 commit comments