Camelia, the Perl 6 bug

IRC log for #mojo, 2012-07-18

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
00:04 GitHub143 joined #mojo
00:04 GitHub143 [mojo] kraih pushed 1 new commit to master: http://git.io/5VSHHQ
00:04 GitHub143 [mojo/master] added closure support to or method - Sebastian Riedel
00:04 GitHub143 left #mojo
00:05 sri moritz: that's what you wanted right?
00:11 sri or should we just run the closure without printing a message and leve the diag call it it?
00:12 * sri scratches head
00:12 sri $t->status_is(200)->or(sub { diag $t->tx->res->dom->at('title')->text })
00:19 tempire seems to me ->or($t->tx->res->dom->at('title')->text) makes the most sense
00:20 tempire that's the whole purpose, right?  to print diagnostic messages?
00:24 tempire hey!
00:24 tempire miyagawa added cpanfile support to cpanm
00:24 tempire \o/
00:24 tempire today, even
00:25 sri tempire: you tell me!
00:25 sri and it's ->or(sub {...}) not ->or(...)
00:26 tempire ->or(sub {}) isn't as sexy
00:26 sri it can't work any other way though
00:27 * sri starts to dislike ->or()
00:35 marty_ joined #mojo
00:35 rem_lex|pivo joined #mojo
00:35 athenot_ joined #mojo
00:35 tempire_ joined #mojo
00:36 gryphon_ joined #mojo
00:37 kthakore joined #mojo
00:37 kvorg joined #mojo
00:37 bjoernfan joined #mojo
00:37 phips joined #mojo
00:37 perlite joined #mojo
00:38 DaTa joined #mojo
00:39 tokuhirom joined #mojo
00:39 avenj joined #mojo
00:39 omega joined #mojo
00:39 [R] joined #mojo
00:39 noganex joined #mojo
00:39 robinsmidsrod joined #mojo
00:39 jwang joined #mojo
00:39 freman joined #mojo
00:39 njlg joined #mojo
00:39 trone joined #mojo
00:39 burk joined #mojo
00:39 migo joined #mojo
00:39 ryanc joined #mojo
00:39 nic joined #mojo
00:39 jzawodn joined #mojo
00:39 janliesendahl_de joined #mojo
00:39 stephan48 joined #mojo
00:39 angelixd joined #mojo
00:39 jmmills joined #mojo
00:39 gizzlon joined #mojo
00:39 whee joined #mojo
00:39 atrodo joined #mojo
00:39 charsbar__ joined #mojo
00:39 garu joined #mojo
00:39 MisterHatt joined #mojo
00:39 tholen joined #mojo
00:39 ZadYree joined #mojo
00:39 kenjiskywalker joined #mojo
00:39 hide joined #mojo
00:39 bzero joined #mojo
00:39 BinGOs joined #mojo
00:39 xxtjaxx_ joined #mojo
00:42 estrai joined #mojo
00:42 yko joined #mojo
00:42 Patterner joined #mojo
00:42 marcus joined #mojo
00:42 alnewkirk joined #mojo
00:42 jnap joined #mojo
00:42 diegok joined #mojo
00:42 graf joined #mojo
00:42 mire joined #mojo
00:42 zivester_ joined #mojo
00:42 heytrav joined #mojo
00:42 dbr joined #mojo
00:42 preflex joined #mojo
00:42 geira joined #mojo
00:42 x86 joined #mojo
00:42 Ulti joined #mojo
00:42 dotan joined #mojo
00:42 rwstauner joined #mojo
00:42 plu joined #mojo
00:42 Annihitek joined #mojo
00:42 crab joined #mojo
00:42 ashleydev joined #mojo
00:42 kmx joined #mojo
00:42 keedi joined #mojo
00:42 nuba joined #mojo
00:42 tinx joined #mojo
00:42 gabiruh joined #mojo
00:42 tomi-ru joined #mojo
00:42 spacebat joined #mojo
00:42 sri https://github.com/kraih/mojo/commit/a8​60d8214d5502854923bd893b57feb07a7c2cf0
00:42 sri and changed again
00:42 sri i went with the simplest solution
00:42 sri since it is easy to test and versatile
00:49 GitHub54 joined #mojo
00:49 GitHub54 [mojo] kraih pushed 1 new commit to master: http://git.io/8qdFLw
00:49 GitHub54 [mojo/master] better tests for or method - Sebastian Riedel
00:49 GitHub54 left #mojo
00:50 laouji joined #mojo
00:52 bird joined #mojo
00:56 GitHub31 joined #mojo
00:56 GitHub31 [mojo] kraih pushed 1 new commit to master: http://git.io/JpIhHA
00:56 GitHub31 [mojo/master] better example for or method - Sebastian Riedel
00:56 GitHub31 left #mojo
00:59 sri ok, i think that's ok now
01:03 GabrielVieira joined #mojo
01:08 GabrielVieira Hey there, I'm trying to do async db requests using Mojolicious + DBIx::Custom + Mojo::IOLoop, but I'm getting examples with Mojo::UserAgent.. anyone have any example that could be closer to what I'm trying to?
01:09 asarch joined #mojo
01:33 scott_ joined #mojo
01:39 GitHub139 joined #mojo
01:39 GitHub139 [mojo] kraih pushed 1 new commit to master: http://git.io/t1kcgA
01:39 GitHub139 [mojo/master] better mode tests - Sebastian Riedel
01:39 GitHub139 left #mojo
01:53 preflex_ joined #mojo
01:58 d4rkie joined #mojo
02:08 noganex_ joined #mojo
02:17 zivester_ joined #mojo
02:36 Psyche^ joined #mojo
02:48 GitHub4 joined #mojo
02:48 GitHub4 [mojo] kraih pushed 2 new commits to master: http://git.io/eCqAsA
02:48 GitHub4 [mojo/master] fixed a few small encoding bugs in Test::Mojo - Sebastian Riedel
02:48 GitHub4 [mojo/master] fixed small selector bug in Test::Mojo - Sebastian Riedel
02:48 GitHub4 left #mojo
03:22 GitHub37 joined #mojo
03:22 GitHub37 [mojo] kraih pushed 1 new commit to master: http://git.io/ZYn4rw
03:22 GitHub37 [mojo/master] improved default descriptions for many methods in Test::Mojo - Sebastian Riedel
03:22 GitHub37 left #mojo
03:22 amirite joined #mojo
03:24 tempire_ marcus: I don't know when it changed, but I love the new nordaaker.com
03:49 d4rkie joined #mojo
04:04 omega the text looks horrible in firefox on mac though :(
04:05 zivester joined #mojo
04:28 D4RK-PH0ENiX joined #mojo
04:31 tempire the text always looks horrible on firefox
04:32 tempire every time I check a site in it I raise an eyebrow
04:52 omega well in this case it is just a matter of changing font-weight from lighter to 200
04:52 omega maybe safari and firefox interprets the lighter differently?
04:52 omega esp when set on body
04:56 omega (lighter is suposed to be one level lighter than the parent, which might be strange when set on body)
05:06 xaka joined #mojo
05:36 ovnimancer joined #mojo
05:47 spleenjack joined #mojo
05:48 AmeliePoulain joined #mojo
05:49 AmeliePoulain joined #mojo
05:50 Coff joined #mojo
06:00 Leandr joined #mojo
06:09 Foxcool joined #mojo
06:55 tempire I have an idea!  But I can't tell you, I have to show you.
06:55 tempire https://sphotos-b.xx.fbcdn.net/hphotos-ash4​/417111_10150671601056383_1350483517_n.jpg
07:01 keedi joined #mojo
07:03 moritz left #mojo
07:14 taryk joined #mojo
07:15 Vandal joined #mojo
07:22 negher joined #mojo
07:38 cosmincx joined #mojo
07:40 pau4o joined #mojo
07:50 smpb joined #mojo
07:56 cosmincx joined #mojo
07:57 iambatman joined #mojo
08:03 fhelmber_ joined #mojo
08:48 marcus hypnotoad!
08:48 marcus tempire: thanks
08:48 marcus omega: sorry, didn't know anyone used firefox still :-p
08:50 omega the day any other browser gets better, I'll switch
08:51 marcus wow, firefox looks so shit on retina mbp
08:52 marcus (just downloaded 14.0.1)
08:53 omega lucky for me I don't have that problem
08:54 marcus omega: even the text is rendered low-res
08:55 marcus omega: I see there's a little bit of difference in the font weight, yeah
08:55 omega on my non-retina, with font-weight: 200 it looks the same in safari, but much better in firefox
08:57 preflex_ joined #mojo
08:57 marcus my font-designer guy agrees that lighter is bullshit.
08:59 marcus updated nordaaker.com now.
08:59 omega esp on something like body, because the inheritance gets wonky I think
09:02 spleenjack1 joined #mojo
09:04 marcus nordaaker.no looks even better on a retina display btw ;)
09:04 marcus unless you're using firefox of course
09:11 omega the text looks good on my non-retina now, so I am happy :p
09:11 marcus \o/
09:13 xaka joined #mojo
09:16 bird joined #mojo
09:20 Patterner joined #mojo
09:54 Debolaz[Lo] joined #mojo
10:04 spleenjack joined #mojo
10:08 Coff joined #mojo
10:09 edenc joined #mojo
10:16 fhelmber_ joined #mojo
10:39 mire joined #mojo
10:53 jamesw joined #mojo
11:01 nic I can't get a response out of typecastapp.com
11:01 * nic sheds a little tear
11:01 nic Any website worth its salt makes it explicit which model of computer you require for viewing its fonts
11:02 nic and then throws a popup taking you to a website to buy the required hardware
11:14 Coff joined #mojo
12:09 daxim joined #mojo
12:15 sri \o\
12:15 sri /o/
12:17 samuelw joined #mojo
12:19 Debolaz[Lo] sri: You forgot me. :-P
12:20 samuelw Hello, does anybody know if its possible in some way to send command line arguments to a script you start using hypnotoad? I.e $> hypnotoad myscript.pl —config=my_cfg (want to read ARGV['config'] in myscript.pl)
12:25 zhutingting joined #mojo
12:30 sri https://github.com/kraih/mojo/pull/355 # hahahaha, you know me too well :)
12:32 sri nic: but why rename stack to queue?
12:34 tadamo joined #mojo
12:34 GitHub19 joined #mojo
12:34 GitHub19 [mojo] kraih pushed 2 new commits to master: http://git.io/6jRs0w
12:34 GitHub19 [mojo/master] Better support in Mojo::Cache for multiple ->set() - Nic Sandfield
12:34 GitHub19 [mojo/master] Merge pull request #355 from niczero/master - Sebastian Riedel
12:34 GitHub19 left #mojo
12:39 nic oh hi
12:40 nic sri: surely it's a fifo -- calling it a stack is plain confusing
12:40 nic (it never gets popped)
12:40 zhutingting left #mojo
12:41 sri agreed
12:41 nic \o/
12:41 * nic retires
12:41 zhutingting joined #mojo
12:47 GitHub126 joined #mojo
12:47 GitHub126 [mojo] kraih pushed 1 new commit to master: http://git.io/_PnbnA
12:47 GitHub126 [mojo/master] updated Changes file - Sebastian Riedel
12:47 GitHub126 left #mojo
12:59 tadamo_ joined #mojo
13:04 jnap joined #mojo
13:05 crab sri: did you draw your icon by hand?
13:05 sri crab: which icon?
13:06 crab sri: github, twitter etc.
13:06 crab the sunglasses and smug smile. ;-)
13:07 sri ah, nope, that was drawn by a professional
13:16 mire joined #mojo
13:27 iambatman fg
13:27 iambatman oops :)
13:34 inokenty joined #mojo
13:39 * marty waves
13:39 * Coff rocks
13:48 * marty took the plunge and purchased sublime text 2 today.
13:54 memowe_ joined #mojo
13:54 gryphon joined #mojo
13:54 xaka joined #mojo
14:03 nic diegok: If I had a project called 'mojar', are there any slang meanings I should be aware of, other than what the dictionary says?
14:13 zhutingting joined #mojo
14:21 CromeDome joined #mojo
14:22 sri everybody happy with ->or() now? http://mojolicio.us/perldoc/Test/Mojo#or
14:28 marty ->or() looks good to me.  Seems to make sense in some situations.
14:29 gryphon joined #mojo
14:31 zhutingting joined #mojo
14:34 zhutingting I use morbo command to run myapp. But when I change the app.pl It send an error and shutdown
14:35 zhutingting I am using win7 activistate perl
14:38 samuelw left #mojo
14:50 tempire ->or is fine to me.  although it seems to me that if the main purpose is to use diag, why not just take a string directly and pass it to diag?
14:50 * tempire agrees that his name should be used in the docs
14:51 sri tempire: what do you mean with "just take a string directly and pass it to diag"?
14:51 tempire ->or('this message') would internally do diag 'this message'
14:51 sri that seems pretty useless
14:51 sri why would you want to print static diag messages?
14:52 sri most common use to me seems to be introspection for ua, app and tx
14:53 tempire whether it's 'string' or $t->tx->res->dom->at('title')->text, it's still static from the perspective of ->or, since it gets rendered as a string.
14:53 tempire render is the wrong word.
14:53 sri you mean ->or($t->tx->res->dom->at('title')->text)?
14:53 tempire right
14:53 sri that doesn't work
14:54 sri $t->tx is undefined at the time
14:54 tempire ooOOOOooooh
14:54 sri or worse, contains the previously processed transation
14:54 sri *+c
14:54 tempire well then
14:54 * tempire redacts
14:56 sri only real option would be implicit diag() call for the callback return value, which might limit its versatility
14:57 tempire I like that idea, but doing arbitrary things in the sub could be really useful
14:58 * sri nods
15:08 alester joined #mojo
15:20 crab hm. i'm going to largely avoid fetching json from the server and using js templating on the client.
15:20 tempire did something go horribly wrong?
15:22 crab not horribly wrong, no. but mojo templating lets me not worry about XSS at all, and using JSON/client-side templates means i have to worry about it in more places.
15:23 tempire I haven't done anything with client templates.  Seems to me it would complicate the issue.  Maybe using js on server and client would lesson the complication.
15:23 crab also, i have come to hate the small delay between page load and filling in the data with client-side templates. and it's a pain to maintain similar templates on server and client side.
15:24 sri doesn't mustache.js do escaping for you?
15:26 crab sri: it's not that it can't be done in one way or another. it's more a matter of conservatism. rely on one mechanism to protect against xss, rather than mechanism a in place x and mechanism b in place y.
15:26 * tempire always looks at the dep list for cpan modules now, and tends to shy away if they use lwp
15:26 * sri is not a fan of client side templating either though
15:26 crab xss is the kind of thing that creeps up on you when you're not paying attention, so i'm just trying to reduce the number of things to pay attention to.
15:28 crab maybe if i used node.js on the server, i would feel differently about it because i could use the same templates on client and server.
15:28 tempire I can feel that pull getting stronger a little each day
15:29 pau4o left #mojo
15:29 crab but i'm very much not willing to write all my code in javascript for just that one benefit.
15:30 tempire that's really what it comes down to in the end
15:30 tempire but the functional interfaces to js make it seem really interesting to me
15:31 crab what functional interfaces?
15:31 tempire like http://osteele.com/sources/javascript/functional/
15:32 crab i've seen a few packages that were pretty intriguing too. someone wrote an LDAP implementation in js. if i had a need for ldap, i could imagine using node.js just for that.
15:39 sri well, with js on both sides you have new dangers :)
15:41 tempire mojolicious talk @ yapc::eu announced!
15:41 tempire with a live tutorial
15:41 tempire gutsy
15:41 sri \o/
15:41 CromeDome joined #mojo
15:42 mercutioviz joined #mojo
15:44 sri tempire: just try node.js, the grass is not greener
15:46 sri some things are better, some things are worse, but more people with node.js experience will surely benefit mojolicious development :)
15:47 sri they get stream apis very right imo
15:53 daniel_ joined #mojo
16:15 * tempire loves the state keyword
16:16 sri tempire: what do you use it for?
16:17 tempire using it to retrieve a remote json document on the first request a daemon receives
16:17 tempire caching for low-volume sites
16:17 sri ah
16:17 sri in mojolicious we use it exactly once
16:17 sri https://github.com/kraih/mojo/blo​b/master/lib/Mojo/IOLoop.pm#L158
16:20 Leandr joined #mojo
16:34 * nic loves how readable the Mojolicious code is
16:34 * inokenty too
16:39 tempire I wish you could do $obj->method(shift, shift) for qw/ key value key2 value2 /;
16:39 tempire or something to that effect
16:41 tempire 'cause then you could manage $obj->shift(shift) for qw/.../ with some trickery
16:41 tempire and force functional flow
17:12 crab that stuff is really easy to overuse
17:18 * sri loves $obj->FooClass::foo_method() and thinks that stuff is underused
17:20 sri perl -Mojo -E 'sub foo { shift->render_text("Foo!") } a("/" => sub { shift->main::foo() })->start' get /
17:26 diegok nic: 'mojar' in argentinian slang can be 'fuck', but it's not so strong and only in argentinian spanish ;)
17:30 inokenty1 joined #mojo
17:30 diegok nic: 'mojar la chaucha' is like 'dip the seedcase' :-p
17:30 * marty is waiting for the day (real soon now) when someone writes a complete app in a mojo one-liner.
17:31 sri perl -Mojo -E 'a({json => {time => time}})->start' daemon
17:31 sri how about a time server? :)
17:31 diegok sri++ :)
17:32 marty sri wins the prize!
17:32 sri \o/
17:39 ki0_ joined #mojo
17:39 mire joined #mojo
17:40 vasundhar joined #mojo
17:48 rem_lex| joined #mojo
17:56 Coff joined #mojo
18:08 niski joined #mojo
18:09 xaka joined #mojo
18:31 rem_lex|pivo joined #mojo
18:43 ilbot2 joined #mojo
18:43 Topic for #mojo is now Mojolicious real-time web framework 3.0 🌈 http://mojolicio.us 🌈 http://irclog.perlgeek.de/mojo/today
18:43 janliesendahl_de joined #mojo
18:44 burk joined #mojo
18:44 tardisx joined #mojo
18:44 chansen joined #mojo
18:44 diegok joined #mojo
18:45 augensalat joined #mojo
18:46 MisterHatt joined #mojo
18:46 d4rkie joined #mojo
18:46 niski joined #mojo
18:46 edenc joined #mojo
18:46 zivester joined #mojo
18:46 estrai joined #mojo
18:46 yko joined #mojo
18:46 marcus joined #mojo
18:46 alnewkirk joined #mojo
18:46 heytrav joined #mojo
18:46 dbr joined #mojo
18:46 geira joined #mojo
18:46 x86 joined #mojo
18:46 Ulti joined #mojo
18:46 rwstauner joined #mojo
18:46 plu joined #mojo
18:46 Annihitek joined #mojo
18:46 ashleydev joined #mojo
18:46 kmx joined #mojo
18:46 nuba joined #mojo
18:46 tinx joined #mojo
18:46 gabiruh joined #mojo
18:46 spacebat joined #mojo
18:46 jzawodn joined #mojo
18:46 mercutioviz joined #mojo
18:46 tholen joined #mojo
18:46 hide joined #mojo
18:46 tomi-ru joined #mojo
18:46 CromeDome joined #mojo
18:46 tadamo_ joined #mojo
18:46 keedi joined #mojo
18:46 xxtjaxx_ joined #mojo
18:46 tokuhirom joined #mojo
18:46 avenj joined #mojo
18:46 omega joined #mojo
18:46 [R] joined #mojo
18:46 robinsmidsrod joined #mojo
18:46 jwang joined #mojo
18:46 freman joined #mojo
18:46 njlg joined #mojo
18:46 trone joined #mojo
18:46 migo joined #mojo
18:46 ryanc joined #mojo
18:46 nic joined #mojo
18:46 stephan48 joined #mojo
18:46 angelixd joined #mojo
18:46 jmmills joined #mojo
18:46 gizzlon joined #mojo
18:46 whee joined #mojo
18:46 atrodo joined #mojo
18:46 charsbar__ joined #mojo
18:50 memowe joined #mojo
18:58 niski hi, got one question regarding form_for
18:59 niski is there any case when (method => 'POST') would be ignored?
19:01 niski http://pastebin.com/90HCfaWp
19:01 niski I have 2 get routes which share same template - in '/add' the form has method="POST" set
19:02 niski in '/edit/...' - no method attribute
19:02 marty { method => 'POST' }  ???
19:03 niski 1sec
19:03 marty So, short answer is
19:04 marty no.   (method => 'POST') will not be ignored but { method => 'POST' } will be ignored.  :)
19:04 niski thanks ;)
19:04 marty sorry, I hit my enter key instead of backspace.  :)
19:05 niski I wonder why '/add' worked...
19:06 * marty is still getting used to his itty-bitty keyboard.
19:07 tempire easel.io looks really great.
19:14 marcus w.easel.io
19:15 tempire jimcav.easel.io
19:25 d4rkie joined #mojo
19:45 tempire hmm.  Mojo::URL->host isn't populated in $self->req->url?
19:46 sri dumper it
19:46 sri you should know why it's the case by now ;p
19:47 * sri suspects tempire just forgot
19:47 tempire I saw it in base
19:47 * tempire fails at life
19:48 * sri gives tempire a cookie
19:48 tempire I vaguely remember a conversation about this.
19:49 sri we preserve the base url if we can
19:49 tempire but I must have forgotten all the relevant information.
19:49 sri base path for cgi and the like
19:49 tempire ooh
19:50 sri https://github.com/kraih/mojo/b​lob/master/t/mojo/request_cgi.t
19:50 sri lots of examples
19:50 tempire http://i2.kym-cdn.com/photos/ima​ges/newsfeed/000/234/786/bf7.gif
19:51 * sri cheers
19:52 sri not even sure if preserving the base url makes any sense anymore these days
19:52 fhelmber_ joined #mojo
19:53 sri it's from a time when url_for didn't generate absolute paths
19:53 sri perhaps someone should look into it *hint hint*
19:54 * tempire is too excited to work on his new website
19:55 sri https://github.com/kraih/mojo/​blob/master/t/mojo/url.t#L632 # <- url merging is fun!
19:56 sri oh right, we need to preserve the base
19:56 sri because reverse proxy with path prefix
19:57 sri nginx with myapp.pl deployed under /myapp... a request for /myapp/foo/bar needs to be translated to /foo/bar for the router
19:58 sri and the base needs to be preserved for urls generated by url_for
19:58 sri which need to be /myapp/foo/bar agan
19:58 sri *+i
19:58 sri fun!
19:59 sri same for cgi/psgi of course
20:02 tempire derp
20:02 tempire I was thinking about it incorrectly
20:02 tempire ->to_abs is the magic I was trying to do manually
20:03 * tempire spends too much time in textbooks
20:03 sri indubitably
20:04 * sri wants someone to work on the 4.0 architecture for him
20:04 tempire indentured servitude is the answer
20:05 fhelmber_ joined #mojo
20:05 * sri accelerates world domination plans
20:08 sri watching the http working group is like watching a soap opera, latest topic "mandated TLS for more privacy on the web"
20:08 tempire mandate all the things
20:09 * marty mandates ice cream for everyone in the chat room
20:09 tempire reviews of my yapc presentation came in
20:10 * sri approves
20:10 tempire most relevant improvement suggestion: "Larger beard."
20:10 tadamo_ joined #mojo
20:11 * sri nods
20:12 tempire looks like most people think I knew what I was talking about
20:12 tempire and the ratings indicate overall high marks
20:13 tempire some people wanted more tutorial howtos
20:13 tempire eh.  that's what docs are for.
20:13 tempire and screencasts
20:16 * sri wants more screencasts :)
20:16 * tempire hides behind the desk labeled mongodb driver
20:16 sri -.-
20:16 sri then motivate me! ;p
20:16 tempire with screencasts?
20:17 * sri shrugs
20:37 andrefs joined #mojo
20:50 Liam` joined #mojo
20:50 xantus joined #mojo
20:51 xantus purl?
20:58 * marty ponders how to motivate a Supervillain of the Perl universe.
21:00 marcus marty: with cookies?
21:01 marty I got it.  PHP kicks Mojolicous's A$$ cuz it ain't got no mongodb secret sauce!
21:01 marty Cookies was my second thought.  :)
21:02 marty mmmmm , cooookiees.
21:03 * marty watched a documentary called "being elmo" and now has a new appreciation for Elmo.
21:06 marcus looks good
21:09 crab joined #mojo
21:26 sri elmo++
21:48 lukep joined #mojo
21:53 andrefs joined #mojo
21:58 iambatman joined #mojo
22:02 memowe_ joined #mojo
22:30 drift joined #mojo
22:44 diegok mongodb driver ++
22:44 diegok :)
23:17 sri hmm, think i'll extend the Mojolicious::Static api a little
23:18 sri thinking my $asset = app->static->file('foo/bar.html') and app->static->serve_asset($c, $asset)
23:20 sri makes the last modified and range support reusable
23:20 sri and of course it's less lines of code :)
23:45 GitHub132 joined #mojo
23:45 GitHub132 [mojo] kraih pushed 1 new commit to master: http://git.io/EWBm4A
23:45 GitHub132 [mojo/master] added file and serve_asset methods to Mojolicious::Static - Sebastian Riedel
23:45 GitHub132 left #mojo
23:48 sri i don't care particularly about the methods, but the code is easier to maintain now
23:50 sri static was always my least favorite code, now it's acceptable imo
23:51 sri not sure though if ->file() should be renamed to ->get_file()... so it's in line with ->get_data_template() from the renderer
23:51 * sri scratches head
23:51 zhutingting joined #mojo

| Channels | #mojo index | Today | | Search | Google Search | Plain-Text | summary