Fixed logging example