File tree 3 files changed +3
-9
lines changed 3 files changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -102,12 +102,6 @@ public bool IsValidDomain(string fullyQualifiedDomainName)
102
102
return false ;
103
103
}
104
104
105
- var domainDataStructure = this . _ruleProvider . GetDomainDataStructure ( ) ;
106
- if ( domainDataStructure == null || domainDataStructure . TldRule == null )
107
- {
108
- return false ;
109
- }
110
-
111
105
if ( string . IsNullOrEmpty ( domainInfo . Domain ) )
112
106
{
113
107
return false ;
@@ -136,7 +130,7 @@ public bool IsValidDomain(string fullyQualifiedDomainName)
136
130
}
137
131
138
132
var domainDataStructure = this . _ruleProvider . GetDomainDataStructure ( ) ;
139
- if ( domainDataStructure == null )
133
+ if ( domainDataStructure == null || domainDataStructure . TldRule == null )
140
134
{
141
135
throw new NullReferenceException ( "DomainDataStructure is not available" ) ;
142
136
}
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ namespace Nager.PublicSuffix.RuleParsers
9
9
/// </summary>
10
10
public class TldRuleParser
11
11
{
12
- private readonly char [ ] _lineBreak = new char [ ] { '\n ' , '\r ' } ;
12
+ private readonly char [ ] _lineBreak = [ '\n ' , '\r ' ] ;
13
13
14
14
/// <summary>
15
15
/// ParseRules
Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ public class StaticRuleProvider : BaseRuleProvider
16
16
/// <param name="domainDataStructure"></param>
17
17
public StaticRuleProvider ( DomainDataStructure domainDataStructure )
18
18
{
19
- this . _domainDataStructure = domainDataStructure ;
19
+ base . _domainDataStructure = domainDataStructure ;
20
20
}
21
21
22
22
/// <summary>
You can’t perform that action at this time.
0 commit comments