fixed bug in scaffold