Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

update with latest js

  • Loading branch information...
commit fdba6822b70f94bc83cfa3ed9274a4ac0f97c635 1 parent 0e06acd
@fat fat authored
Showing with 4 additions and 8 deletions.
  1. +4 −8 1.3.0/bootstrap-twipsy.js
View
12 1.3.0/bootstrap-twipsy.js
@@ -90,7 +90,8 @@
actualWidth = $tip[0].offsetWidth
actualHeight = $tip[0].offsetHeight
- placement = _.maybeCall(this.options.placement, this.$element[0])
+
+ placement = maybeCall(this.options.placement, this, [ $tip[0], this.$element[0] ])
switch (placement) {
case 'below':
@@ -193,15 +194,10 @@
/* TWIPSY PRIVATE METHODS
* ====================== */
- var _ = {
-
- maybeCall: function ( thing, ctx ) {
- return (typeof thing == 'function') ? (thing.call(ctx)) : thing
- }
-
+ function maybeCall ( thing, ctx, args ) {
+ return typeof thing == 'function' ? thing.apply(ctx, args) : thing
}
-
/* TWIPSY PLUGIN DEFINITION
* ======================== */
Please sign in to comment.
Something went wrong with that request. Please try again.