Skip to content

Commit ed2779d

Browse files
committed
Skip removing path if not in the path.
1 parent 160000c commit ed2779d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

toolbox/src/bossdevice.m

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,9 @@ function initOscillationProps(obj)
105105
fprintf('[Debug] Using own full installation of Speedgoat I/O Blockset v%s.\n',speedgoat.version);
106106

107107
% Remove any possible instance of SG dependencies from the path
108-
rmpath(genpath(obj.sgDepsPath));
108+
if exist('sg','dir')
109+
rmpath(genpath(obj.sgDepsPath));
110+
end
109111

110112
elseif isfolder(fullfile(obj.sgDepsPath,matlabRelease.Release))
111113
% Try using built-in Speedgoat dependency

0 commit comments

Comments
 (0)