No, Rihanna's management paid Sia so no one could take the song, but Beyonce paid probably higher and took it.
Did you guys listen to the video? It was sent to Katy first. Katy somehow missed it. Rihanna's people got it and put it on hold (for 8 months) but in an oversight didn't pay for it and Beyoncé's people managed to snatch it due to that oversight.