fix logger closure