Skip to content
This repository was archived by the owner on Dec 24, 2022. It is now read-only.

Commit 76293a6

Browse files
committed
fix build for PCL
1 parent 98229bd commit 76293a6

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/ServiceStack.Text/LicenseUtils.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,11 +162,12 @@ public static void AssertEvaluationLicense()
162162
public static void RegisterLicense(string licenseKeyText)
163163
{
164164
string cutomerId = null;
165+
#if !PCL
165166
var hold = Thread.CurrentThread.CurrentCulture;
166-
167+
Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
168+
#endif
167169
try
168170
{
169-
Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
170171
var parts = licenseKeyText.SplitOnFirst('-');
171172
cutomerId = parts[0];
172173

@@ -200,7 +201,9 @@ public static void RegisterLicense(string licenseKeyText)
200201
}
201202
finally
202203
{
204+
#if !PCL
203205
Thread.CurrentThread.CurrentCulture = hold;
206+
#endif
204207
}
205208
}
206209

0 commit comments

Comments
 (0)