fbauth 1.2.T.1 → 1.2.T.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,11 +1,23 @@
1
1
  - if auto_resize
2
2
  :javascript
3
- $(document).ready(function() {
3
+ window.fbAsyncInit = function() {
4
4
  FB.init({appId: '#{FacebookConfig['app_id']}', status: true, cookie: true, xfbml: true, channelUrl: '#{channel_url}'});
5
5
  FB.Canvas.setAutoResize();
6
- });
6
+ if (typeof window.fbAuthInit == 'function') {
7
+ window.fbAuthInit();
8
+ }
9
+ };
7
10
  - else
8
11
  :javascript
9
- $(document).ready(function() {
12
+ window.fbAsyncInit = function() {
10
13
  FB.init({appId: '#{FacebookConfig['app_id']}', status: true, cookie: true, xfbml: true});
11
- });
14
+ if (typeof window.fbAuthInit == 'function') {
15
+ window.fbAuthInit();
16
+ }
17
+ };
18
+ :javascript
19
+ (function() {
20
+ var e = document.createElement('script'); e.async = true;
21
+ e.src = document.location.protocol + '//connect.facebook.net/en_US/all.js';
22
+ document.getElementById('fb-root').appendChild(e);
23
+ }());
@@ -1,9 +1,9 @@
1
1
  :javascript
2
- $(document).ready(function() {
2
+ window.fbAuthInit = function() {
3
3
  fbauth_hide_panels();
4
4
  FB.getLoginStatus(function(response) { fbauth_update_page(response); });
5
5
  FB.Event.subscribe('auth.statusChange', function(response) { fbauth_update_page(response); });
6
- });
6
+ };
7
7
  function fbauth_hide_panels() {
8
8
  $('#{login_el}').hide();
9
9
  $('#{add_el}').hide();
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fbauth
3
3
  version: !ruby/object:Gem::Version
4
- hash: 227
4
+ hash: 229
5
5
  prerelease: 4
6
6
  segments:
7
7
  - 1
8
8
  - 2
9
9
  - T
10
- - 1
11
- version: 1.2.T.1
10
+ - 2
11
+ version: 1.2.T.2
12
12
  platform: ruby
13
13
  authors:
14
14
  - Three Wise Men Inc.