Stop object form being dragged on another

I have a tile based game where tiles can be dragged out. how do i make it so you can’t drop tiles on a square that already has a tile?

A solution is to create a small square sprite (say 2x2), and place that at the centre of the square the tile is dropped onto. Then check for a collision between the small square sprite and a tile. If there is a collision, then don’t drop the tile.

Note, you may need to reposition the dragged tile away from where it’s being dropped so the collision between it and the small square sprite isn’t registered, and then move it back after the collision check. This can all be done in 1 or two events, and won’t be seen on screen as it’s all done before the redraw of the scene.