princess 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/lib/princess/excelx_reader.rb +2 -2
  2. metadata +3 -3
@@ -3,7 +3,7 @@ module Princess
3
3
 
4
4
  def initialize(filename)
5
5
  @filename = filename
6
- active_sheet(1)
6
+ active_sheet(0)
7
7
  end
8
8
 
9
9
  # load a sheet for reading
@@ -18,7 +18,7 @@ module Princess
18
18
  @shared_strings = noko_shared_strings.xpath('//sst/si/t').map(&:content)
19
19
 
20
20
  # grab spreadsheet content
21
- doc = Nokogiri::XML(zipfile.read("xl/worksheets/sheet#{sheet_num}.xml"))
21
+ doc = Nokogiri::XML(zipfile.read("xl/worksheets/sheet#{sheet_num + 1}.xml"))
22
22
  doc.remove_namespaces!
23
23
  ref = doc.xpath('//dimension').first.attr('ref')
24
24
  @rows = Array.new(ref.split(':').last.scan(/\d+/).first.to_i)
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: princess
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 23
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 3
10
- version: 0.0.3
9
+ - 4
10
+ version: 0.0.4
11
11
  platform: ruby
12
12
  authors:
13
13
  - R. Scott Reis