diff options
author | Walter Bender <walter@sugarlabs.org> | 2013-07-25 20:38:38 (GMT) |
---|---|---|
committer | Walter Bender <walter@sugarlabs.org> | 2013-07-25 20:38:38 (GMT) |
commit | 7fcbc8b6e7ccc07776d92c0535edc5bd5681e005 (patch) | |
tree | e5931351df1885a8cb026173a09cd8c12d8fd162 /plugins/turtle_blocks_extras/turtle_blocks_extras.py | |
parent | 0aa7f0e5e65e96fb8f32ffcdf0b1112f26988899 (diff) |
fix problems with non-interactive mode
Diffstat (limited to 'plugins/turtle_blocks_extras/turtle_blocks_extras.py')
-rw-r--r-- | plugins/turtle_blocks_extras/turtle_blocks_extras.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/turtle_blocks_extras/turtle_blocks_extras.py b/plugins/turtle_blocks_extras/turtle_blocks_extras.py index beb9bfb..8f5a94d 100644 --- a/plugins/turtle_blocks_extras/turtle_blocks_extras.py +++ b/plugins/turtle_blocks_extras/turtle_blocks_extras.py @@ -957,7 +957,8 @@ Journal objects')) ''' User-defined macros are saved as a json-encoded file; these get loaded into a palette on startup ''' - if os.path.exists(self.tw.macros_path): + if hasattr(self.tw, 'macros_path') and \ + os.path.exists(self.tw.macros_path): files = glob.glob(os.path.join(self.tw.macros_path, '*.tb')) debug_output('making myblocks palette', self.tw.running_sugar) if len(files) > 0: |