Story highlights Melissa Nelson worked as a dental assistant for James Knight for more than 10 years

Knight complained Nelson wore tight clothes, was a "detriment" to his family

Knight's wife demanded he fire Nelson; he did

The all-male high court rules her termination did not constitute unlawful discrimination

Can a boss fire an employee he finds attractive because he and his wife, fairly or not, see her as a threat to their marriage?

Yes, the Iowa Supreme Court ruled Friday.

"The question we must answer is ... whether an employee who has not engaged in flirtatious conduct may be lawfully terminated simply because the boss views the employee as an irresistible attraction," Justice Edward M. Mansfield wrote for the all-male high court.

Such firings may not be fair, but they do not constitute unlawful discrimination under the Iowa Civil Rights Act, the decision read, siding with a lower court.

An attorney for Melissa Nelson, the fired employee, said the decision was wrong.

"We are appalled by the court's ruling and its failure to understand the nature of gender bias," said Paige Fiedler, the attorney. "For the seven men on the Iowa Supreme Court not to 'get it' is shocking and disheartening. It underscores the need for judges on the bench to be diverse in terms of their gender, race and life experiences."

The case concerns her client's employment as a dental assistant. Nelson worked for James Knight in 1999 and stayed for more than 10 years at the Fort Dodge business.

Toward the end of her employment, Knight complained to Nelson her clothing was tight and "distracting," the decision read. She denied her clothes were inappropriate.

At one point, Knight told Nelson that "if she saw his pants bulging, she would know her clothing was too revealing," the decision read.

At another point, in response to an alleged comment Nelson made about the infrequency of her sex life, Knight responded: [T]hat's like having a Lamborghini in the garage and never driving it."

During the last six months of Nelson's employment, Nelson and Knight, both married with children, started sending text messages to each other outside of work. Neither objected to the texting.

Knight's wife, who was employed at the same dental office, found out about those messages in late 2009 and demanded he fire Nelson.

In early 2010, he did just that. In the presence of a pastor, Knight told Nelson she had become a "detriment" to his family and that for the sakes of both their families, they should no longer work together, the decision read. Knight gave Nelson one month's severance.

In a subsequent conversation between Knight and Nelson's husband, Knight said Nelson had done nothing wrong and that "she was the best dental assistant he ever had," the decision read.

Nelson filed a lawsuit, contending that Knight fired her because of her gender. She did not say he committed sexual harassment.

In response, Knight argued that Nelson was fired because of the "nature of their relationship and the perceived threat" to his marriage, not because of her gender. In fact, he said, Knight only employs women and replaced Nelson with another female employee.

A district court sided with Knight; Nelson appealed.

"As we have indicated above, the issue before us is not whether a jury could find that Dr. Knight treated Nelson badly," read the high court's decision.

"We are asked to decide only if a genuine fact issue exists as to whether Dr. Knight engaged in unlawful gender discrimination when he fired Nelson at the request of his wife. For the reasons previously discussed, we believe this conduct did not amount to unlawful discrimination, and therefore we affirm the judgment of the district court."