Adding possibility not to log to a file