Lawmakers in Uruguay have agreed to allow adoptions by gay and lesbian couples, the AP reported Thursday.

The measure was approved in a 40 to 13 vote by the 99-seat Chamber of Representatives. Remaining members were absent from the vote. Senators, who previously approved the measure on a first reading, are expected to pass the final bill.

Uruguay began recognizing the relationships of gay and lesbian couples last year with civil unions, a move that has placed the tiny Latin American country at odds with its more conservative neighbors. In May, President Tabare Vazquez signed a decree lifting a decades-old ban on gays serving in the military.

The bill was passed over the objections of the Roman Catholic Church, which claims sixty-six percent of the country as members, and social conservatives.

Nicolas Cotugno, the archbishop of Montevideo, said before the vote that allowing gay couples to adopt would be a “serious error.”

“It's not about religion, philosophy or sociology. It's something which is mainly about the respect of human nature itself,” Catugno said in a statement.