Fix: Prevent type error when dragging an object

Thanks for the fix, Nathan!