Shape bugfixes