Using the piecewise function above, what is the value of f(-1)

ioTo determine the piecewise function below:
[tex]f(x)=\begin{cases}2x+8\text{ x}\leq-2 \\ x^2-3\text{ -23}\end{cases}\text{ }[/tex]The piecewise function above can be solved based on the value of f (x)
The value of the function f(-1) is when x - value is -1
[tex]\begin{gathered} \text{when x }\leq-2\text{ , the values of x ranges from -2, -3, -4, -5, and so on} \\ so\text{ the function is not applicable for the function} \\ f(x)=2x+8 \end{gathered}[/tex]The value of the function f(-1) is when x - value is -1
[tex]\begin{gathered} \text{when -2< x }\leq3\text{ , the values of x ranges from -1, 0, 1, 2, }3 \\ so\text{ the function is applicable for the piecewise function} \\ f(x)=x^2-3 \end{gathered}[/tex][tex]\begin{gathered} f(x)=x^2-3 \\ f(-1)=(-1)^2-3 \\ f(-1)=1-3 \\ f(-1)=-2 \end{gathered}[/tex]Hence the piecewise function of the value of f(-1) = -2