Index: lib/isolate/timer.dart |
diff --git a/lib/isolate/timer.dart b/lib/isolate/timer.dart |
index 8684de73170fcea61ce6438bfdf5cff3bcc5fd2c..72867a7bc0fc84f3f8d7f4a058e6722bed35c702 100644 |
--- a/lib/isolate/timer.dart |
+++ b/lib/isolate/timer.dart |
@@ -9,7 +9,7 @@ abstract class Timer { |
*/ |
factory Timer(int milliSeconds, void callback(Timer timer)) { |
if (_TimerFactory._factory == null) { |
- throw new UnsupportedOperationException("Timer interface not supported."); |
+ throw new StateError("Timer interface not supported."); |
} |
return _TimerFactory._factory(milliSeconds, callback, false); |
} |
@@ -20,7 +20,7 @@ abstract class Timer { |
*/ |
factory Timer.repeating(int milliSeconds, void callback(Timer timer)) { |
if (_TimerFactory._factory == null) { |
- throw new UnsupportedOperationException("Timer interface not supported."); |
+ throw new StateError("Timer interface not supported."); |
} |
return _TimerFactory._factory(milliSeconds, callback, true); |
} |