The problems I have with your definition of morality is that breaking the code/law would translate into an anti-social act rather than an immoral one.
That's not what I said. I was just comparing how the term "objective" is considered in law. Something that's objective is something that's outside a single person's bias and opinions. The law is objective by that standard. By the same standard, morality is also objective. That's not the same as saying that morality and law are themselves the same things. It's like this. An apple is a fruit. An orange is a fruit. But an apple is not an orange. Law is objective. Morality is objective. But Law and morality are two different things.
You say that objective is something outside a person but the sum of other people's subjective morality views does not equal objective morality.
But that's how morality works. If you take a class in sociology, you'll learn that morality is based on common values, mores, attitudes, etc. Morality evolves, and it's founded in the community and its attitudes. It's not up to a single person to decide what the community consider moral, but the community slowly adapt and change its common views.
By your definition "objective" is dependent of majority within a certain community.
Essentially, in this case, yes.
If that's the case, the term "objectively" is no longer necessary and we can focus on moral standards within a certain community, at a certain time. ...
That's usually how it's done in cultural anthropology and sociology.
The problem that arises is that there is still no objective morality by which a community can be judged from outside. IMO the proposal you're making for objective morality is simply not feasible.
That's why I prefer the term "universal" or "absolute" instead of objective, simply because objective is a term that means outside a person's bias and views, not outside a community's bias and views. Objective is misleading and incorrect for what you're looking for, in my opinion. I'd prefer to use clearer language. That was my point. The constant use of objective creates an artificial schism between theists and non-theists. Using a sharper language might help finding better ground for discussion.
I do understand what you're saying, but the term "objective" can be interpreted as "a
: expressing or dealing with facts or conditions as perceived without distortion by personal feelings, prejudices, or interpretations". Which fits for the conditions of a majority of views. The majority of views become the condition that the single person's feelings, prejudice, and interpretation can't fight against. You're opinion about if lying is right or wrong won't change the majority view of it being right or wrong. Morality in society tends to rely on the morality of the majority, independent of your personal views.