SOLVED - How to set revert on a draggable based on the droppable

SOLVED - How to set revert on a draggable based on the droppable

I needed to have a draggable only revert if it was placed on a droppable of a certain class. I found the solution in an undocumented feature: revert can be a callback function. So I used:

revert: function(droppable) {
      // Only revert position if dropped on another tile
      return ($(droppable).hasClass('tile'));
},

I'm not sure why it's not documented, hopefully it's not going to be removed...