Fix #1

Add guard for uniform resizing.