Skip to content
This repository has been archived by the owner on Jan 25, 2025. It is now read-only.

Commit

Permalink
Otherwise lightning icons break in unmanaged code.
Browse files Browse the repository at this point in the history
  • Loading branch information
ceiroa committed Oct 31, 2015
1 parent 719d5f0 commit 13c73f1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/aura/svgIcon/svgIconHelper.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
//This would work with any class. We are just using the one with the shortest name.
var gettingnamespace = sforce.connection.query("SELECT NamespacePrefix FROM ApexClass where Name = 'REL_Utils' LIMIT 1");
var getname = gettingnamespace.getArray("records");
if(getname.length > 0 && getname[0] && getname[0].NamespacePrefix.length > 0) {
if(getname.length > 0 && getname[0] && getname[0].NamespacePrefix && getname[0].NamespacePrefix.length > 0) {
namespace = getname[0].NamespacePrefix + "__";
svgPath = svgPath.replace('/resource/', '/resource/' + namespace);
console.log("svgPath after manipulation: " + svgPath);
Expand Down

0 comments on commit 13c73f1

Please sign in to comment.