Onion Sorry, but this is incorrect.
There is no law requiring this. (If you think there is, then please link to it... all of the laws are available on government web sites).
What is true is that the major carriers required it, and since at the time almost all phones were sold through carriers, the firmware of phones was created in such a way to make shutter sounds.
If you can read Japanese, you can check, for example, this discussion:
https://detail.chiebukuro.yahoo.co.jp/qa/question_detail/q11268664161
(They mention that it isn't a law, just carrier restriction).
For example, Sony sells phones for the Japanese market, on their Japanese web site - And I can tell you from experience that the non-carrier (SIM free) Japan market Xperia models don't have any shutter sounds by default.
https://www.sony.jp/xperia/
This isn't Sony defying the law, just that since it's their store model not sold through any carrier, nobody is forcing them to make the fake shutter sound.
I only bring all of this up, because if it WAS a law, then Graphene OS would be foolish to allow users to easily bypass it, but it isn't, so there is no harm in ignoring it like Sony does.