refactor code
parent
1e7ebdd354
commit
74325fc5a1
|
@ -6,12 +6,5 @@ class MechanizeCr::File
|
||||||
@uri = uri
|
@uri = uri
|
||||||
@body = body
|
@body = body
|
||||||
@code = code
|
@code = code
|
||||||
|
|
||||||
#@full_path = false unless defined? @full_path
|
|
||||||
|
|
||||||
#fill_header response
|
|
||||||
#extract_filename
|
|
||||||
|
|
||||||
#yield self if block_given?
|
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
require "myhtml"
|
require "myhtml"
|
||||||
|
# This is a fake node used when sending post request.
|
||||||
# This is a fake node.
|
|
||||||
class Node < Hash(String,String)
|
class Node < Hash(String,String)
|
||||||
def css(str)
|
def css(str)
|
||||||
[] of Hash(String,String)
|
[] of Hash(String,String)
|
||||||
|
@ -8,7 +7,7 @@ class Node < Hash(String,String)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
||||||
# This is a real Node.
|
# This is a real Node got from html.
|
||||||
struct Myhtml::Node
|
struct Myhtml::Node
|
||||||
delegate :[], to: attributes
|
delegate :[], to: attributes
|
||||||
delegate :[]=, to: attributes
|
delegate :[]=, to: attributes
|
||||||
|
|
Loading…
Reference in New Issue