From f85bdc75c67e9d3b13f26031772e9d5f2eb08cc1 Mon Sep 17 00:00:00 2001 From: Andrea Bogazzi Date: Sun, 19 Feb 2017 17:29:03 -0500 Subject: [PATCH] Update path.class.js (#3713) --- src/shapes/path.class.js | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/src/shapes/path.class.js b/src/shapes/path.class.js index 819b12af821..f1c0e7c8102 100644 --- a/src/shapes/path.class.js +++ b/src/shapes/path.class.js @@ -927,23 +927,7 @@ * @param {Boolean} [forceAsync] Force an async behaviour trying to create pattern first */ fabric.Path.fromObject = function(object, callback, forceAsync) { - // remove this pattern rom 2.0, accept just object. - var path; - if (typeof object.path === 'string') { - fabric.loadSVGFromURL(object.path, function (elements) { - var pathUrl = object.path; - path = elements[0]; - delete object.path; - - fabric.util.object.extend(path, object); - path.setSourcePath(pathUrl); - - callback && callback(path); - }); - } - else { - return fabric.Object._fromObject('Path', object, callback, forceAsync, 'path'); - } + return fabric.Object._fromObject('Path', object, callback, forceAsync, 'path'); }; /* _FROM_SVG_START_ */