public function setExportFolder(string $folder)
    {
        $folder = trailingslashit($folder);

        if (!file_exists($folder)) {
            if (!mkdir($folder)) {
                trigger_error('The export folder (' . $folder .') can not be found. Exports will not be saved.', E_USER_WARNING);
            } else {
                chmod($folder, 0777);
            }
        }

        $this->exportFolder = $folder;
    }