From dcab9c101311d249e519bf396905bb6a76c82057 Mon Sep 17 00:00:00 2001 From: Tianwei Du Date: Fri, 14 Sep 2018 02:02:39 +0800 Subject: [PATCH] Add connection.getCheck function #2048 (#2049) * Add connection.getCheck function #2048 * remove unused argument * fix eslint error * fix eslint error --- core/connection.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/core/connection.js b/core/connection.js index 91a6f19a7..2832dfe73 100644 --- a/core/connection.js +++ b/core/connection.js @@ -603,6 +603,13 @@ Blockly.Connection.prototype.setCheck = function(check) { return this; }; +/** + * Get a connection's compatibility. + * @return {Array} List of compatible value types. + */ +Blockly.Connection.prototype.getCheck = function() { + return this.check_; +}; /** * Change a connection's shadow block. * @param {Element} shadow DOM representation of a block or null.