Here I would do `perms.orElse(dirPermissions).foreach { ... }`, so we fall back on the logger's permissions if they exist. That way if we intend for all our files to have one set of permissions (e.g. in event logging) we don't have to provide `Some(permissions)` every time.