From 7d4859506a796af50f5cc23baee870b322f93688 Mon Sep 17 00:00:00 2001 From: Jason Chen Date: Sun, 23 Oct 2016 12:58:25 -0700 Subject: [PATCH] support debug: true --- core/quill.js | 3 +++ docs/_includes/standalone/snow.html | 3 ++- docs/docs/api/extension.md | 4 ++-- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/core/quill.js b/core/quill.js index 50a97c701e..ceaaa8a1a2 100644 --- a/core/quill.js +++ b/core/quill.js @@ -14,6 +14,9 @@ let debug = logger('quill'); class Quill { static debug(limit) { + if (limit === true) { + limit = 'log'; + } logger.level(limit); } diff --git a/docs/_includes/standalone/snow.html b/docs/_includes/standalone/snow.html index eec8961312..ca04b04800 100644 --- a/docs/_includes/standalone/snow.html +++ b/docs/_includes/standalone/snow.html @@ -22,7 +22,8 @@ \ No newline at end of file diff --git a/docs/docs/api/extension.md b/docs/docs/api/extension.md index c417dfcefe..a0e54e955c 100644 --- a/docs/docs/api/extension.md +++ b/docs/docs/api/extension.md @@ -2,12 +2,12 @@ ### debug -Static method enabling logging messages at a given level: `'error'`, `'warn'`, `'log'`, or `'info'`. +Static method enabling logging messages at a given level: `'error'`, `'warn'`, `'log'`, or `'info'`. Passing `true` is equivalent to passing `'log'`. Passing `false` disables all messages. **Methods** ```javascript -Quill.debug(level: String) +Quill.debug(level: String | Boolean) ``` **Examples**