Fixed a bug in removeAttachment()

> 'if (isset($this->attachment[0]))'
> should be
> 'if (isset($this->attachment[$index]))'

same for unset($this->attachment[0])