Added write-log