Added non null checks on counter methods