I have studied the Fourier transform and the inverse Fourier transform for functions in $L^1(\mathbb{R})$, so in 1D. In my book, I see the following definition:
If $f \in L^1(\mathbb{R})$ and its Fourier transform $\hat{f} \in L^1(\mathbb{R})$, then the inverse Fourier transform of $\hat{f}(\omega)$ is defined by: $g(t) = \mathcal{F}^{-1}\{\hat{f}(\omega)\} = \dots $.
Additionally, $g=f$ for almost every $t \in \mathbb{R}$. If the original $f$ is continuous, then $g=f$ for every $t \in \mathbb{R}$.
I don't understand how that is possible. I imagine that a function in $f \in L^1(\mathbb{R})$ could be discontinuous almost everywhere. But by applying Fourier transform and inverse Fourier transform, I will receive a function $g$ that is continuous on $\mathbb{R}$.
By the proposition above, this would be a fatal issue.
What am I thinking wrong?
You are absolutely right that there are functions $f\in L^1$ sucht that there is no continuous function $g$ with $f=g$ almost everywhere.
Nevertheless, the statement that you cite is true: If in addition to $f\in L^1$ you assume $\hat{f}\in L^1$, then $f=\mathcal{F}^{-1}\hat{f}$ almost everywhere, where the right hand side is continuous.
In particular, this shows that if $f$ is such that there is no continuous $g$ with $f=g$ almost everywhere, then you must have $\hat{f}\notin L^1$.