In 1782, Virginia passed a law permitting manumission and over the next eight years more than 10,000 slaves were given their freedom. With support from Benjamin Franklin, in 1790 the Quakers petitioned Congress to abolish slavery; the number of abolitionist movements greatly increased, and by 1804 all the northern states had outlawed it. However, even many like Adams who viewed slavery as a 'foul contagion' opposed the 1790 petition as a threat to the Union. In 1808, Jefferson passed legislation banning the importation of slaves, but allowed the domestic slave trade to continue, arguing the federal government had no right to regulate individual states.