Prevents errors when assigning the same texture to both slots (cherry picked from commit 0648cc65b2)
0648cc65b2