Sha256: 8b5fa816e8169e456a623fef04997a1f28bc795cdd9cc3116638e06943184c09
Contents?: true
Size: 980 Bytes
Versions: 7
Compression:
Stored size: 980 Bytes
Contents
module Fog module Compute class DigitalOcean # noinspection RubyStringKeysInHashInspection class Real def delete_server(server_id) Fog::Logger.warning("delete_server method has been deprecated, use destroy_server instead") destroy_server(server_id) end def destroy_server(server_id) request( :expects => [204], :headers => { 'Content-Type' => "application/json; charset=UTF-8", }, :method => 'DELETE', :path => "/v2/droplets/#{server_id}", ) end end # noinspection RubyStringKeysInHashInspection class Mock def delete_server(server_id) destroy_server(server_id) end def destroy_server(_) response = Excon::Response.new response.status = 204 response end end end end end
Version data entries
7 entries across 5 versions & 2 rubygems