Fix the other check of stackable in default sort.

Separate the checks out into their own method because it can be useful other places as well.