From ac2f43b9b39276ecd154237dcce8f2c486ddc4be Mon Sep 17 00:00:00 2001 From: nov Date: Fri, 6 Feb 2015 12:47:37 +0900 Subject: [PATCH] "identifier" as an alias of "id" for easy fb_graph -> fb_graph2 migration and remove unnecessary attribute registration close #35 --- lib/fb_graph2/app.rb | 2 +- lib/fb_graph2/node.rb | 1 + lib/fb_graph2/tagged_profile.rb | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/fb_graph2/app.rb b/lib/fb_graph2/app.rb index 73454ca..e09ceb1 100644 --- a/lib/fb_graph2/app.rb +++ b/lib/fb_graph2/app.rb @@ -16,7 +16,7 @@ module FbGraph2 register_attributes( raw: [ - :id, :android_key_hash, :app_domains, :auth_dialog_data_help_url, :auth_dialog_headline, + :android_key_hash, :app_domains, :auth_dialog_data_help_url, :auth_dialog_headline, :auth_dialog_perms_explanation, :auth_referral_enabled, :auth_referral_extended_perms, :auth_referral_friend_perms, :auth_referral_user_perms, :canvas_fluid_height, :canvas_fluid_width, :canvas_url, :category, :company, :contact_email, :creator_uid, :daily_active_users, :daily_active_users_rank, diff --git a/lib/fb_graph2/node.rb b/lib/fb_graph2/node.rb index d7fe680..1ef40b0 100644 --- a/lib/fb_graph2/node.rb +++ b/lib/fb_graph2/node.rb @@ -1,6 +1,7 @@ module FbGraph2 class Node attr_accessor :id, :access_token, :raw_attributes + alias_method :identifier, :id def self.inherited(klass) klass.send :include, AttributeAssigner diff --git a/lib/fb_graph2/tagged_profile.rb b/lib/fb_graph2/tagged_profile.rb index ab52328..4fca74a 100644 --- a/lib/fb_graph2/tagged_profile.rb +++ b/lib/fb_graph2/tagged_profile.rb @@ -1,7 +1,7 @@ module FbGraph2 class TaggedProfile < Node register_attributes( - raw: [:id, :name, :type, :offset, :length], + raw: [:name, :type, :offset, :length], custom: [:object] )