Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
fluttertpc_get
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
Tiago da Costa Peixoto
2020-08-08 16:19:55 -0300
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
e928ca0ae010ae34ecd1bd424bb0b442c78afb0a
e928ca0a
1 parent
14a5fa09
fix typos
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
lib/src/instance/get_instance.dart
lib/src/instance/get_instance.dart
View file @
e928ca0
...
...
@@ -117,12 +117,12 @@ class GetInstance {
S
findByType
<
S
>(
Type
type
,
{
String
tag
})
{
String
key
=
_getKey
(
type
,
tag
);
return
GetConfig
.
_singl
[
key
].
get
S
ependency
()
as
S
;
return
GetConfig
.
_singl
[
key
].
get
D
ependency
()
as
S
;
}
void
startController
<
S
>({
String
tag
})
{
String
key
=
_getKey
(
S
,
tag
);
final
i
=
GetConfig
.
_singl
[
key
].
get
S
ependency
();
final
i
=
GetConfig
.
_singl
[
key
].
get
D
ependency
();
if
(
i
is
DisposableInterface
)
{
i
.
onStart
();
...
...
@@ -134,7 +134,7 @@ class GetInstance {
// final key = _getKey(S, tag);
// if (GetConfig._singl.containsKey(key)) {
// return GetConfig._singl[key].get
S
ependency() as S;
// return GetConfig._singl[key].get
D
ependency() as S;
// } else {
// if (GetConfig._factory.containsKey(key)) {
// S _value = put<S>((GetConfig._factory[key].builder() as S), tag: tag);
...
...
@@ -166,7 +166,7 @@ class GetInstance {
}
initDependencies
<
S
>();
return
GetConfig
.
_singl
[
key
].
get
S
ependency
()
as
S
;
return
GetConfig
.
_singl
[
key
].
get
D
ependency
()
as
S
;
}
else
{
if
(!
GetConfig
.
_factory
.
containsKey
(
key
))
throw
"
$S
not found. You need call put<
$S
>(
$S
()) before"
;
...
...
Please
register
or
login
to post a comment