Class: Yt::Collections::Subscriptions
- Inherits:
-
Base
- Object
- Base
- Yt::Collections::Subscriptions
show all
- Defined in:
- lib/yt/collections/subscriptions.rb
Instance Method Summary
collapse
Methods inherited from Base
#initialize, of, #where
#first!
Instance Method Details
#delete_all(params = {}, options = {}) ⇒ Object
17
18
19
20
|
# File 'lib/yt/collections/subscriptions.rb', line 17
def delete_all(params = {}, options = {})
throttle
do_delete_all params, options
end
|
#insert(options = {}) ⇒ Object
8
9
10
11
12
13
14
15
|
# File 'lib/yt/collections/subscriptions.rb', line 8
def insert(options = {})
throttle
do_insert
rescue Yt::Error => error
ignorable_error = error.reasons.include? 'subscriptionDuplicate'
ignorable_error ||= (@parent.id == @auth.channel.id) if @auth
raise error unless options[:ignore_errors] && ignorable_error
end
|