Inject
This commit is contained in:
parent
e1684330a9
commit
cdfc734271
3 changed files with 8 additions and 3 deletions
|
@ -1,6 +1,6 @@
|
||||||
# angel_framework
|
# angel_framework
|
||||||
|
|
||||||
[](https://pub.dartlang.org/packages/angel_framework)
|
[](https://pub.dartlang.org/packages/angel_framework)
|
||||||
[](https://travis-ci.org/angel-dart/framework)
|
[](https://travis-ci.org/angel-dart/framework)
|
||||||
|
|
||||||
Core libraries for the Angel Framework.
|
Core libraries for the Angel Framework.
|
|
@ -34,7 +34,6 @@ class Controller {
|
||||||
"All controllers must carry an @Expose() declaration.");
|
"All controllers must carry an @Expose() declaration.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
final routable = new Routable(debug: true);
|
final routable = new Routable(debug: true);
|
||||||
configureRoutes(routable);
|
configureRoutes(routable);
|
||||||
|
|
||||||
|
@ -80,6 +79,12 @@ class Controller {
|
||||||
if (req.injections.containsKey(name)) {
|
if (req.injections.containsKey(name)) {
|
||||||
args.add(req.injections[name]);
|
args.add(req.injections[name]);
|
||||||
continue;
|
continue;
|
||||||
|
} else if (name == "req") {
|
||||||
|
args.add(req);
|
||||||
|
continue;
|
||||||
|
} else if (name == "res") {
|
||||||
|
args.add(res);
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
final type = parameter.type.reflectedType;
|
final type = parameter.type.reflectedType;
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
name: angel_framework
|
name: angel_framework
|
||||||
version: 1.0.0-dev.37
|
version: 1.0.0-dev.38
|
||||||
description: Core libraries for the Angel framework.
|
description: Core libraries for the Angel framework.
|
||||||
author: Tobe O <thosakwe@gmail.com>
|
author: Tobe O <thosakwe@gmail.com>
|
||||||
homepage: https://github.com/angel-dart/angel_framework
|
homepage: https://github.com/angel-dart/angel_framework
|
||||||
|
|
Loading…
Reference in a new issue