Mailinglist Archive: yast-devel (233 mails)

< Previous Next >
Re: [yast-devel] Re: [yast-commit] <rest-service> registration : add debug output and context default
  • From: "J. Daniel Schmidt" <jdsn@xxxxxxx>
  • Date: Mon, 12 Oct 2009 11:11:50 +0200
  • Message-id: <200910121111.51110.jdsn@xxxxxxx>
On Friday 09 October 2009 08:33:28 Josef Reidinger wrote:
def create

Hi, please don't add debugging output as puts. It is not rails way,

+ puts @reg.inspect
+ return @reg.inspect

Returning inspect, which should change in next rails version is not good

This stuff is only development-debugging output, as the registration does not
work correctly yet. I just want to understand why and until where I get and
what the data is. None of the return *.inspect will remain, its just for a
quick look inside.
Thats why the code is in a branch. To master I will only commit cleaned up

At overall I think that you overload controller layer. It should be thin
layer which connect model with view. I think that many your methods should
go to model. Controller should contain only model initialization and model
changing. Rest model manipulation should go to model. Look e.g. at time
module or language, how thin should be controller layer.

After removing all puts the controller is very thin. The only thing thats will
be done there is parsing the post/put-data and adding it the the registration
object (see the TODO mark).

But thanks for your hints, I will take them into account.


J. Daniel Schmidt <jdsn@xxxxxxx> SUSE Linux Products GmbH
Research & Development Maxfeldstr. 5
GF: Markus Rex, HRB 16746 (AG Nürnberg) D-90409 Nürnberg
To unsubscribe, e-mail: yast-devel+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: yast-devel+help@xxxxxxxxxxxx

< Previous Next >