adding trapping action
updated trapclass, maybe works