Fix assign to empty. 

Closes #889.