implementing commit