silvioprog / brookframework

Microframework which helps to develop web Pascal applications.
https://github.com/risoflora/brookframework
GNU Lesser General Public License v3.0
171 stars 37 forks source link

:name not working #139

Closed MFernstrom closed 6 years ago

MFernstrom commented 7 years ago

According to https://brookframework.org/doc/BrookAction.TBrookAction.html#Register I should be able to register urls such as /user/:id, and be able to read that value with Values.Values['id'].

I get Identifier not found "Values", however.

Is this a known bug or OSX-issue?

leledumbo commented 7 years ago

Without any code, we can only guess:

MFernstrom commented 7 years ago

I'm using the latest code, downloaded and rebuilt just now.

I'm inside an action, where I register a path such as TUser.Register('/user/:id');

According to the docs I should be able to do Values.Values['id'], but I get the error.

leledumbo commented 7 years ago

OK, I didn't realize that it has been renamed to Variables instead of Values, the docs need update.

MFernstrom commented 7 years ago

Aha, that did the trick.

Thanks again, leledumbo, I owe you at least a keg of beer at this point.

I'll leave this open for now, since there's a discrepancy between the docs and reality.

MFernstrom commented 7 years ago

It looks like the docs are still wrong, how do we get them updated?

leledumbo commented 7 years ago

how do we get them updated?

Somebody commit and push the change (well, I practically have the permission to do so...)

silvioprog commented 6 years ago

Hi dudes. First, thanks for reporting and using Brook, and sorry for late answers. @leledumbo you I'll be able to push commits/PR etc., because I added you (and @MFernstrom too) as developer of the Risoflora organization. I'm inclined to move Brook framework to this organization! :-) Closing because the documentation I'll be updated in the new release that is coming in next days.