'From etoys4.0 of 8 September 2009 [latest update: #2267] on 8 September 2009 at 4:49:10 pm'! "Change Set: sugarDirEntries-bf Date: 8 September 2009 Author: Bert Freudenberg Handle ByteArrays we get from the Datastore instead of Strings. This was breaking saving under recent Sugar, wonder why nobody noticed?"! !SugarDatastoreDirectory methodsFor: 'file directory' stamp: 'bf 9/8/2009 16:43'! entries "Return a collection of directory entries for the files and directories in this directory." ^(SugarLauncher current findJournalEntries: self query properties: #('uid' 'title' 'ctime' 'mtime' 'file-size')) collect: [:props | props keysAndValuesDo: [:key :value | props at: key put: value asString]. DirectoryEntry name: (((props at: 'title') copyReplaceAll: '/' with: '\') contractTo: 64) utf8ToSqueak, '-', (props at: 'uid'), self extension creationTime: ([(DateAndTime fromString: (props at: 'ctime')) asSeconds] ifError: [0]) modificationTime: ([(DateAndTime fromString: (props at: 'mtime')) asSeconds] ifError: [0]) isDirectory: false fileSize: (props at: 'file-size' ifAbsent: [42]) ]! !