There is but one gospel law, and it is by that law that all men must be judged (see Romans 2:11-15; see Bruce R. McConkie, Doctrinal New Testament Commentary 2:222).
Our God is just and merciful. When we are given a law—whenever opportunities for obedience are made available—the Almighty expects us to be true to those divine directives.
When, however adequate opportunities for understanding are not available to us through circumstances beyond our control, God will hold us guiltless in regard to that law until a time when compliance is possible.
The law of justification thus demands that all who are saved in the celestial kingdom must have conformed to the laws requisite for entrance into that kingdom. None will so attain under false pretense.
“For all who will have a blessing at my hands shall abide the law which was appointed for that blessing, and the conditions thereof, as were instituted from before the foundation of the world”
(D&C 132:5).
The law of justification also assures that no person in all eternity will be punished for disobedience to a law of which he or she was ignorant. No child of God will be eternally disadvantaged for noncompliance with a principle or for non-observance of an ordinance of which he or she had no knowledge.
In short, there is not a soul who will be deprived of he opportunity for all of the blessings of exaltation because the fulness of gospel law was not to be had during his mortal sojourn.