Due to a misplaced closing bracket, the rest of ResolveUniform() function's code is placed inside the first loop, even Unbind(), which may lead to false behavior.
Instead of reformat the whole function's code (spacing, indent, etc..) I just remove and replace that bracket to show that the rest of the code (other than the misplaced bracket) remain unchanged.
Due to a misplaced closing bracket, the rest of ResolveUniform() function's code is placed inside the first loop, even Unbind(), which may lead to false behavior. Instead of reformat the whole function's code (spacing, indent, etc..) I just remove and replace that bracket to show that the rest of the code (other than the misplaced bracket) remain unchanged.