add cleanup to camera plugin