# Left action of a group on permutation representation

I am studying my course on permutation representation, and I am stuck at understanding the left action of a finite group on the permutation representation $$F(X,\Bbb C)$$. In my course it is given for $$(g,\phi)\in G\times F(X,\Bbb C)$$ by:

$$g*\phi(x\in X)\to \phi(g^{-1}x)$$.

Is this a left group action?

I have: $$h*(g*\phi(x))= h*\phi(g^{-1}x)= \phi(h^{-1}g^{-1}x) = \phi((gh)^{-1}x)= (gh)*\phi(x) \neq (hg)*\phi(x)$$.

I must be missing something.

Note that by the definition $$g*\phi$$ is in $$F(X,\mathbb C)$$ defined by $$(g*\phi)(x):= \phi(g^{-1}x)$$, so the calculation is the following: \begin{align} (h*(g*\phi))(x)&= (g*\phi)(h^{-1}x)\\ &= \phi(g^{-1}h^{-1}x)\\ &= \phi((hg)^{-1}x)\\ &= (hg*\phi)(x). \end{align} Thus $$h*(g*\phi)= hg*\phi$$.
In addition to the accepted answer I want to point out that one can also start by substituting the inner expression. Since $$(g*\phi)(x) := \phi(g^{-1}x)$$, we have $$g*\phi = x \to \phi(g^{-1}x)$$, therefore
\begin{align} (h*(g*\phi))(x) &= (h*(t\to\phi(g^{-1}t)))(x)\\ &= (t\to\phi(g^{-1}t))(h^{-1}x)\\ &= \phi(g^{-1}(h^{-1}x))\\ &= (hg*\phi)(x). \end{align}