# File lib/spreadsheet/excel/writer/workbook.rb, line 76 def complete_sst_update? workbook stored = workbook.sst.collect do |entry| entry.content end num_total = 0 current = worksheets(workbook).inject(Hash.new(0)) do |memo, worksheet| worksheet.strings.each do |k,v| memo[k] += v num_total += v end memo end current.delete '' if !stored.empty? && stored.all?{|x| current.include?(x) } ## if all previously stored strings are still needed, we don't have to # rewrite all cells because the sst-index of such string does not change. additions = current.keys - stored [:partial_update, num_total, stored + additions] else [:complete_update, num_total, current.keys] end end