Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
public
/
sequelize
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
不要怂,就是干,撸起袖子干!
Commit 08c32bc8
authored
Jun 29, 2012
by
sdepold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
store importCache in sequelize instance
1 parent
7331aab5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
4 deletions
lib/sequelize.js
lib/sequelize.js
View file @
08c32bc
...
...
@@ -41,6 +41,8 @@ module.exports = (function() {
this
.
daoFactoryManager
=
new
DAOFactoryManager
(
this
)
this
.
connectorManager
=
new
ConnectorManager
(
this
,
this
.
config
)
this
.
importCache
=
{}
}
Sequelize
.
Utils
=
Utils
...
...
@@ -73,13 +75,13 @@ module.exports = (function() {
return
factory
}
var
importCache
=
{};
Sequelize
.
prototype
.
import
=
function
(
path
)
{
if
(
!
importCache
[
path
])
{
if
(
!
this
.
importCache
[
path
])
{
var
defineCall
=
require
(
path
)
importCache
[
path
]
=
defineCall
(
this
,
DataTypes
)
this
.
importCache
[
path
]
=
defineCall
(
this
,
DataTypes
)
}
return
importCache
[
path
];
return
this
.
importCache
[
path
]
}
Sequelize
.
prototype
.
migrate
=
function
(
options
)
{
...
...
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment