The Trunk: EToys-tpr.340.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: EToys-tpr.340.mcz

commits-2
tim Rowledge uploaded a new version of EToys to project The Trunk:
http://source.squeak.org/trunk/EToys-tpr.340.mcz

==================== Summary ====================

Name: EToys-tpr.340
Author: tpr
Time: 18 February 2019, 7:30:07.021016 pm
UUID: d1ed1a6e-a62f-4178-bcd6-0fb6684301e8
Ancestors: EToys-kfr.339

Part of deprecating HTTPClient for 6.0
Stop using it

=============== Diff against EToys-kfr.339 ===============

Item was changed:
  ----- Method: ServerDirectory class>>parseEToyUserListFrom: (in category '*eToys-school support') -----
  parseEToyUserListFrom: urlString
  | url userString userList |
  urlString ifNil:[^nil].
  url := urlString asUrl.
  userString := ["Note: We need to prevent going through the plugin API
  when retrieving a local (file) URL, since the plugin API
  (correctly) rejects file:// downloads."
  Cursor wait showWhile:[
  (url hasRemoteContents) ifTrue:[
  "Go through the browser (if present)"
+ (HTTPSocket httpGet: url asString) contents.
- (HTTPClient httpGet: url asString) contents.
  ] ifFalse:[
  "Go grab it directly"
  url retrieveContents contents.
  ].
  ].
  ] on: Error do:[nil].
  userString ifNil:[^nil].
  userList := userString lines collect: [:each| each withBlanksTrimmed].
  userList := userList reject:[:any| any isEmpty].
  (userList first = '##user list##') ifFalse:[^nil].
  userList := userList copyFrom: 2 to: userList size.
  ^userList!