Added clear to the constructor (bugfix)