I tried to safe **two** `ints` with `SharedPreferences` in one file. I don´t know if that is possible, because I can only save one of them. I´m not sure if I made a mistake in the code or if it´s not possible to save to different values in **one** `StatefulWidget`. Does anybody see a mistake in my code or can tell me if it is theoretically possible to safe two values in one file? Below is the code of my two safe requests.

Safe requests one (that one **works**):

```
 int lastLoginInt = 1;
 String nameKey = "_key_name";
@override
  void initState() {
    super.initState();
  }

  Future<bool> saveLastLoginInt() async {
    SharedPreferences preferences = await SharedPreferences.getInstance();
    return await preferences.setInt(nameKey, lastLoginInt);
  }

  Future<int> loadLastLoginInt() async {
    SharedPreferences preferences = await SharedPreferences.getInstance();
    return preferences.getInt(nameKey);
  }

  setLastLoginInt() {
    loadLastLoginInt().then((value) {
      setState(() {
        lastLoginInt = value;
      });
    });
  }

```

And this is my second request (which **doesn´t work**):

```
String nameKey1 = "_key_name2";
int countInt = 0;
Future<bool> saveCount() async {
    SharedPreferences preferences = await SharedPreferences.getInstance();
    return await preferences.setInt(nameKey1, countInt);
  }

  Future<int> loadCount() async {
    SharedPreferences preferences = await SharedPreferences.getInstance();
    return preferences.getInt(nameKey1);
  }

  setCount() {
    loadLastLoginInt().then((value) {
      setState(() {
        countInt = value;
      });
    });
  }

```

Hopefully it´s an easy to solve problem. Thank´s in advance!