title: sign in The method '_mulFromInteger' was called on null
body: <p>I've got sign in methode in my provider.</p>
  
  <pre><code>  Future&lt;void&gt; signIn(
        String email, String password, BuildContext context) async {
      SharedPreferences sharedPreferences = await SharedPreferences.getInstance();
      final clientID = "com.super.app";
      final body = "username=$email&amp;password=$password&amp;grant_type=password";
      final String clientCredentials =
          const Base64Encoder().convert("$clientID:".codeUnits);
  
      try {
        final http.Response response =
            await http.post("http://localhost:8888/auth",
                headers: {
                  "Content-Type": "application/x-www-form-urlencoded",
                  "Authorization": "Basic $clientCredentials"
                },
                body: body);
        final jsonResponse = json.decode(response.body);
  //      if (jsonResponse["error"] != null) {
  //        throw HttpException(jsonResponse["error"]);
  //      }
        _userId = 1;
        _token = jsonResponse['access_token'];
        _expiryDate = DateTime.now().add(
          Duration(
            seconds: jsonResponse['expires_in'],
          ),
        );
        _autoLogout();
        notifyListeners();
        final userData = json.encode(
          {
            'userId': 1,
            'email': email,
            'token': _token,
            'expiryDate': _expiryDate.toIso8601String(),
          },
        );
        sharedPreferences.setString('userData', userData);
      } catch (error) {
        print(error.toString()); //&lt;-- misleading error
      }
    }
  </code></pre>
  
  <p>All works fine but when incorrect login credential are passed then I get misleading error </p>
  
  <pre><code>flutter: NoSuchMethodError: The method '_mulFromInteger' was called on null.
  Receiver: null
  Tried calling: _mulFromInteger(1000000)
  </code></pre>
  
  <p>The back end passing error code 400 and body {"error": "invalid client"} but I get that strange error as output. So what does that error means and why do I get that instead of body</p>