added check for isset($data['thesis'])