allow registering for notifications only once

if you call startLogging several times log messages appear several times too. of course, the same can be achieved by avoiding to call startLogging several times. I think this solution is more robust to misusage.