i think that this method is in attachmentsService already. Done better than this. You can't use it?