mirror of
https://github.com/Hopiu/bootstrap.git
synced 2026-04-21 12:44:43 +00:00
Use getOrCreateInstance on _initializeOnDelegatedTarget
This commit is contained in:
parent
92c7056619
commit
3716603dbc
1 changed files with 1 additions and 9 deletions
|
|
@ -439,15 +439,7 @@ class Tooltip extends BaseComponent {
|
|||
// Private
|
||||
|
||||
_initializeOnDelegatedTarget(event, context) {
|
||||
const dataKey = this.constructor.DATA_KEY
|
||||
context = context || Data.get(event.delegateTarget, dataKey)
|
||||
|
||||
if (!context) {
|
||||
context = new this.constructor(event.delegateTarget, this._getDelegateConfig())
|
||||
Data.set(event.delegateTarget, dataKey, context)
|
||||
}
|
||||
|
||||
return context
|
||||
return context || this.constructor.getOrCreateInstance(event.delegateTarget, this._getDelegateConfig())
|
||||
}
|
||||
|
||||
_getOffset() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue