<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def save(self) -> 'Configuration': """ Saves the configuration settings object to the current user's home directory :return: """


        data = self.load().persistent
        if data is None:
            return self

        directory = os.path.dirname(self._source_path)
        if not os.path.exists(directory):
            os.makedirs(directory)

        path = self._source_path
        with open(path, 'w+') as f:
            json.dump(data, f)

        return self