File tree Expand file tree Collapse file tree 1 file changed +15
-7
lines changed
Expand file tree Collapse file tree 1 file changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -39,20 +39,28 @@ public Include(string id, int position)
3939public record Rule
4040{
4141 [ JsonPropertyName ( "query" ) ]
42- public string Query { get ; init ; }
42+ public string ? Query { get ; init ; }
4343
4444 [ JsonPropertyName ( "match" ) ]
45- public string Match { get ; init ; }
45+ public string ? Match { get ; init ; }
46+
47+ [ JsonPropertyName ( "filter_by" ) ]
48+ public string ? FilterBy { get ; init ; }
49+
50+ [ JsonPropertyName ( "tags" ) ]
51+ public IEnumerable < string > ? Tags { get ; init ; }
4652
4753 [ JsonConstructor ]
48- public Rule ( string query , string match )
54+ public Rule (
55+ string ? query = null ,
56+ string ? match = null ,
57+ string ? filterBy = null ,
58+ IEnumerable < string > ? tags = null )
4959 {
50- if ( string . IsNullOrWhiteSpace ( query ) )
51- throw new ArgumentException ( "cannot be null or whitespace." , nameof ( query ) ) ;
52- if ( string . IsNullOrWhiteSpace ( match ) )
53- throw new ArgumentException ( "cannot be null or whitespace." , nameof ( match ) ) ;
5460 Match = match ;
5561 Query = query ;
62+ FilterBy = filterBy ;
63+ Tags = tags ;
5664 }
5765}
5866
You can’t perform that action at this time.
0 commit comments