Add function to clear mPreparedEdit, to use in cases of mutable content

In Wikibase, EntityContent is mutable and needs to clear
prepared edit before performing a save.

Follow-up to I2c34baa

Change-Id: I770bf2dc960c0a67a9b8315b7cdf24f3b89b6480
(cherry picked from commit 8842bc95fc06c8114e50574cdae33ac8fbf5d6a0)