The following is from the NBA and refers to goaltending. I think this is why the basket was disallowed, but, IMO it is a bit vague?
Goaltending:
When a player shoots the ball, a defender may not touch the ball after it reaches its highest point. If so, the shot shall be ruled successful. A defender also can not touch a shot after it has hit the backboard and is going towards the rim, whether it is going up or down. Once the ball is on or directly above the rim, no player can touch the ball. If an offensive player is guilty in any of the above circumstances, basket interference shall be ruled and no points can be scored. If it is a defender, two or three points shall be scored depending on the type of field goal attempted.