In Casella Berger's Statistical Inference, they define a power function of a hypothesis test with rejection region $R$ to be the function of $\theta$ define by $\beta(\theta) = P_\theta(X\in R)$ for some data $X$. Suppose that $H_0: \theta\in \Theta_0$ and $H_1: \theta \in \Theta_0^c$.
Furthermore, they state that:
$$ P_\theta(X\in R) = \begin{cases} \text{probability of a Type 1 error} &\mbox{if } \theta\in \Theta_0\\ \text{one minus the probability of a Type 2 error} & \mbox{if } \theta\in \Theta_0^c\end{cases} $$
However, my understand is always that the power function is the probability of rejecting the null, given that the null is false. This doesn't match the above. What is wrong here? Thanks!