EXT-5867 : Crash when clicking and dragging root folder of object contents into build floater
EXT-5867 : Crash when clicking and dragging root folder of object contents into build floater

Simple fix to use dynamic cast - the previous unsafe static cast was treating folders as if they were items and then querying permissions, which don't exist for folders.
This code actually existed back in 1.23 but by some stroke of luck worked.

gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm,gabeharms/firestorm