"If a player, with the ball in his possession, raises his pivot foot off the floor, he must pass or shoot before his pivot foot returns to the floor. If he drops the ball while in the air, he may not be the first to touch the ball."
https://official.nba.com/rule-no-10-violations-and-penalties/
He raised his pivot foot in the air and shot it before it returned to the floor. The rule says nothing about whether or not you can rotate on the other foot while this happens.