pop method
T?
pop()
Removes last item is possible and notifies change. It returns the popped item, or null if stack was empty.
Implementation
T? pop() {
try {
final poppedItem = _items.removeLast();
notifyListeners();
return poppedItem;
} catch (e) {
return null;
}
}