remove top handle scope to prevent memory leak