I saw this happening only when the image cannot find the sources file, so it has to decompile the methods. On Mon, Jul 17, 2017 at 7:34 PM, lionelakue <lionelakue@gmail.com> wrote:
Hello everyone,
When you copy an image or sometimes when you make a Metacello commit, your methods are automatically refactored.
This uncleanse the code (replacing context meaningfull variable names with gereric identifiers) and prevents seaside request parameters . Which are mapped to method parameters by uri strings:
ToDoHandler>>searchFor: aString <get> <path: '/search?query={aString}'>
^ String streamContents: [ :stream | ToDoList default items do: [ :each | (each title includesSubString: aString) ifTrue: [ stream nextPutAll: each title; crlf ] ] ]
will become:
ToDoHandler>>searchFor: arg1 <get> <path: '/search?query={aString}'> ^ String streamContents: [ :arg2| ToDoList default items do: [ :arg3| (each title includesSubString: aString) ifTrue: [ arg2 nextPutAll: arg3 title; crlf ] ] ]
So will end having a Parameter not found exception because arg1 and aString mismatche.
Is there a way to disable automatic refactoring?
Lionel
-- View this message in context: http://forum.world.st/Automatic-Refactoring- Disranging-Seaside-Rest-Methods-tp4955422.html Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.