Merge branch 'master' of github.com:haozhu233/kableExtra
diff --git a/R/row_spec.R b/R/row_spec.R
index 49b64b6..c69a4bc 100644
--- a/R/row_spec.R
+++ b/R/row_spec.R
@@ -313,7 +313,11 @@
   } else {
     latex_after <- "\\\\\\\\"
     if (hline_after) {
-      latex_after <- paste0(latex_after, "\n\\\\hline")
+      if (table_info$booktabs) {
+        latex_after <- paste0(latex_after, "\n\\\\midrule")
+      } else {
+        latex_after <- paste0(latex_after, "\n\\\\hline")
+      }
     }
     if (!is.null(extra_latex_after)) {
       latex_after <- paste0(latex_after, "\n",