fix #519, change from 'class' comparison to 'inherits'
diff --git a/R/cell_spec.R b/R/cell_spec.R
index 8a69c1f..5e58b1c 100644
--- a/R/cell_spec.R
+++ b/R/cell_spec.R
@@ -117,10 +117,10 @@
 
   # favor popover over tooltip
   if (!is.null(popover)) {
-    if (class(popover) != "ke_popover") popover <- spec_popover(popover)
+    if (!inherits(popover, "ke_popover")) popover <- spec_popover(popover)
     tooltip_n_popover <- popover
   } else if (!is.null(tooltip)) {
-    if (class(tooltip) != "ke_tooltip") tooltip <- spec_tooltip(tooltip)
+    if (!inherits(tooltip, "ke_tooltip")) tooltip <- spec_tooltip(tooltip)
     tooltip_n_popover <- tooltip
   } else {
     tooltip_n_popover <- NULL