StarlitGhost / PyMoronBot

All development moved to https://github.com/DesertBot/DesertBot - A modular IRC bot with extensive aliasing capabilities, written in Python.
MIT License
9 stars 0 forks source link

Var replacement doesn't always work #103

Closed StarlitGhost closed 8 years ago

StarlitGhost commented 8 years ago

.sub {var url google.com}{slurp text $url title}

Problem fetching http://google.com

.sub {var url google.com}{slurp text {say $url} title}

Google

I suspect the $url isn't actually replaced when slurp is called in the first case, and only appears that way because it has been replaced in the response from slurp.

In the second case, I suspect say is receiving the literal string '$url', but it is replaced in the response before the outer sub-level is executed.

Anyway, it's weird.

StarlitGhost commented 8 years ago

Fixed in 12d5483e7efece5da755e6876d62bb63c7ff6d57