Working version with notifications