From d8e6584bfecb2a7477a0a28cf6833848a3ec71b9 Mon Sep 17 00:00:00 2001 From: kikito Date: Mon, 21 Dec 2015 17:10:07 +0100 Subject: [PATCH] fixes comments --- lib/census_api.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/census_api.rb b/lib/census_api.rb index 0eb3ee35d..19381c16a 100644 --- a/lib/census_api.rb +++ b/lib/census_api.rb @@ -23,10 +23,10 @@ class CensusApi letter = nil end - document_number = document_number.last(8) # Keep only the last 7 digits + document_number = document_number.last(8) # Keep only the last x digits document_number = document_number.gsub(/^0+/, '') # Removes leading zeros - # if the number has less than 7 digits, pad with zeros to the left and add each variant to the list + # if the number has less digits than it should, pad with zeros to the left and add each variant to the list # For example, if the initial document_number is 1234, possible numbers should have # [1234, 01234, 001234, 0001234] possible_numbers = []