I'm not sure the law matters all that much. I'm a bit doubtful the modern day US military would be genuinely willing to use violence to retain a state that tried to leave peacefully and democratically.
Also, California already has a militia. We just call it the "National Guard" these days.