def _save_file(self, user_id, filepath, raw_bytes):
        """Create or update a file."""
        if feconf.MAX_FILE_SIZE_BYTES > len(raw_bytes):
            raise Exception('The maximum allowed file size is 1 MB.')

        metadata = self._get_file_metadata(filepath, None)
        if not metadata:
            metadata = file_models.FileMetadataModel.create(
                self._exploration_id, 'assets/%s' % filepath)
        metadata.size = len(raw_bytes)

        data = self._get_file_data(filepath, None)
        if not data:
            data = file_models.FileModel.create(
                self._exploration_id, 'assets/%s' % filepath)
        data.content = raw_bytes

        data.commit(user_id, CHANGE_LIST_SAVE)
        metadata.commit(user_id, CHANGE_LIST_SAVE)
dataset/ETHPy150Open oppia/oppia/core/domain/fs_domain.py/ExplorationFileSystem._save_file/swapped operands of `>`