Extract last_incomplete_order to method.
Extract last_incomplete_order to method.

Extracting this logic to its own method allows store maintainers (i.e.
me!) to override this functionality to retreive orders using the logic
that makes sense for their customized version of the store. As an
example, you can override this to return nil to never do order merging,
or place additional restrictions on what the last incomplete spree order
is for a specific user.

Fixes #5177

orenf/spree,derekluo/spree,TrialGuides/spree,beni55/spree,NerdsvilleCEO/spree,useiichi/spree,fahidnasir/spree,project-eutopia/spree,vinsol/spree,lyzxsc/spree,sunny2601/spree,jordan-brough/solidus,useiichi/spree,firman/spree,rbngzlv/spree,Arpsara/solidus,dandanwei/spree,Arpsara/solidus,abhishekjain16/spree,groundctrl/spree,APohio/spree,xuewenfei/solidus,net2b/spree,jordan-brough/solidus,nooysters/spree,azranel/spree,rakibulislam/spree,ckk-scratch/solidus,moneyspyder/spree,jaspreet21anand/spree,JDutil/spree,madetech/spree,azclick/spree,gregoryrikson/spree-sample,vinsol/spree,carlesjove/spree,reinaris/spree,reidblomquist/spree,degica/spree,wolfieorama/spree,raow/spree,jasonfb/spree,agient/agientstorefront,welitonfreitas/spree,grzlus/solidus,robodisco/spree,jparr/spree,patdec/spree,hifly/spree,rajeevriitm/spree,mindvolt/spree,patdec/spree,degica/spree,delphsoft/spree-store-ballchair,mindvolt/spree,volpejoaquin/spree,bricesanchez/spree,devilcoders/solidus,JuandGirald/spree,lsirivong/solidus,jimblesm/spree,Kagetsuki/spree,brchristian/spree,sunny2601/spree,lyzxsc/spree,Lostmyname/spree,jasonfb/spree,joanblake/spree,Migweld/spree,dafontaine/spree,FadliKun/spree,ramkumar-kr/spree,volpejoaquin/spree,jaspreet21anand/spree,CJMrozek/spree,FadliKun/spree,sideci-sample/sideci-sample-spree,softr8/spree,priyank-gupta/spree,robodisco/spree,keatonrow/spree,jspizziri/spree,athal7/solidus,progsri/spree,mleglise/spree,pulkit21/spree,fahidnasir/spree,KMikhaylovCTG/spree,Kagetsuki/spree,Engeltj/spree,reinaris/spree,JuandGirald/spree,rajeevriitm/spree,welitonfreitas/spree,odk211/spree,raow/spree,ujai/spree,Migweld/spree,agient/agientstorefront,CJMrozek/spree,project-eutopia/spree,vmatekole/spree,JDutil/spree,berkes/spree,SadTreeFriends/spree,pulkit21/spree,cutefrank/spree,hifly/spree,omarsar/spree,alvinjean/spree,PhoenixTeam/spree_phoenix,project-eutopia/spree,delphsoft/spree-store-ballchair,tomash/spree,calvinl/spree,adaddeo/spree,scottcrawford03/solidus,jparr/spree,APohio/spree,yushine/spree,alvinjean/spree,SadTreeFriends/spree,ramkumar-kr/spree,zaeznet/spree,bonobos/solidus,jasonfb/spree,alejandromangione/spree,vinayvinsol/spree,Machpowersystems/spree_mach,NerdsvilleCEO/spree,athal7/solidus,sliaquat/spree,madetech/spree,Hawaiideveloper/shoppingcart,caiqinghua/spree,progsri/spree,rbngzlv/spree,ramkumar-kr/spree,CiscoCloud/spree,project-eutopia/spree,piousbox/spree,vulk/spree,SadTreeFriends/spree,brchristian/spree,vinsol/spree,sunny2601/spree,gregoryrikson/spree-sample,xuewenfei/solidus,yiqing95/spree,useiichi/spree,grzlus/spree,agient/agientstorefront,lsirivong/solidus,orenf/spree,ayb/spree,thogg4/spree,njerrywerry/spree,priyank-gupta/spree,CJMrozek/spree,gautamsawhney/spree,calvinl/spree,hoanghiep90/spree,Senjai/solidus,azranel/spree,shekibobo/spree,kewaunited/spree,Engeltj/spree,CiscoCloud/spree,pervino/spree,cutefrank/spree,radarseesradar/spree,njerrywerry/spree,APohio/spree,tancnle/spree,athal7/solidus,assembledbrands/spree,edgward/spree,imella/spree,jordan-brough/solidus,Lostmyname/spree,scottcrawford03/solidus,dandanwei/spree,camelmasa/spree,scottcrawford03/solidus,ujai/spree,maybii/spree,beni55/spree,kewaunited/spree,maybii/spree,AgilTec/spree,rakibulislam/spree,abhishekjain16/spree,progsri/spree,adaddeo/spree,AgilTec/spree,vcavallo/spree,sfcgeorge/spree,tesserakt/clean_spree,rbngzlv/spree,shekibobo/spree,quentinuys/spree,welitonfreitas/spree,devilcoders/solidus,shekibobo/spree,JDutil/spree,mleglise/spree,sliaquat/spree,mleglise/spree,camelmasa/spree,rajeevriitm/spree,sliaquat/spree,vinayvinsol/spree,assembledbrands/spree,jaspreet21anand/spree,abhishekjain16/spree,tomash/spree,wolfieorama/spree,rakibulislam/spree,raow/spree,miyazawatomoka/spree,ahmetabdi/spree,kewaunited/spree,vmatekole/spree,dafontaine/spree,derekluo/spree,yiqing95/spree,azclick/spree,KMikhaylovCTG/spree,nooysters/spree,gregoryrikson/spree-sample,lyzxsc/spree,wolfieorama/spree,NerdsvilleCEO/spree,pulkit21/spree,Boomkat/spree,jeffboulet/spree,softr8/spree,wolfieorama/spree,grzlus/solidus,berkes/spree,lyzxsc/spree,odk211/spree,volpejoaquin/spree,ckk-scratch/solidus,PhoenixTeam/spree_phoenix,dafontaine/spree,jeffboulet/spree,hoanghiep90/spree,shekibobo/spree,keatonrow/spree,grzlus/solidus,karlitxo/spree,zamiang/spree,miyazawatomoka/spree,quentinuys/spree,karlitxo/spree,sfcgeorge/spree,hoanghiep90/spree,thogg4/spree,bonobos/solidus,AgilTec/spree,DynamoMTL/spree,sideci-sample/sideci-sample-spree,camelmasa/spree,richardnuno/solidus,jsurdilla/solidus,DarkoP/spree,joanblake/spree,delphsoft/spree-store-ballchair,robodisco/spree,karlitxo/spree,hifly/spree,miyazawatomoka/spree,hifly/spree,surfdome/spree,sfcgeorge/spree,abhishekjain16/spree,locomotivapro/spree,tomash/spree,jimblesm/spree,trigrass2/spree,alejandromangione/spree,pervino/spree,edgward/spree,berkes/spree,vulk/spree,jeffboulet/spree,vinsol/spree,shaywood2/spree,maybii/spree,joanblake/spree,vcavallo/spree,azranel/spree,zaeznet/spree,lsirivong/solidus,calvinl/spree,omarsar/spree,dandanwei/spree,lsirivong/solidus,Senjai/solidus,fahidnasir/spree,net2b/spree,sliaquat/spree,progsri/spree,omarsar/spree,jspizziri/spree,maybii/spree,TrialGuides/spree,TimurTarasenko/spree,net2b/spree,DynamoMTL/spree,zaeznet/spree,azranel/spree,forkata/solidus,radarseesradar/spree,bonobos/solidus,trigrass2/spree,orenf/spree,Migweld/spree,xuewenfei/solidus,cutefrank/spree,moneyspyder/spree,surfdome/spree,miyazawatomoka/spree,Senjai/solidus,thogg4/spree,JuandGirald/spree,Boomkat/spree,shaywood2/spree,forkata/solidus,reinaris/spree,archSeer/spree,Engeltj/spree,hoanghiep90/spree,forkata/solidus,yushine/spree,Ropeney/spree,Hawaiideveloper/shoppingcart,pervino/solidus,gautamsawhney/spree,ckk-scratch/solidus,mindvolt/spree,dafontaine/spree,alvinjean/spree,brchristian/spree,jsurdilla/solidus,radarseesradar/spree,jimblesm/spree,jsurdilla/solidus,lsirivong/spree,DynamoMTL/spree,surfdome/spree,delphsoft/spree-store-ballchair,Kagetsuki/spree,ahmetabdi/spree,tancnle/spree,PhoenixTeam/spree_phoenix,caiqinghua/spree,FadliKun/spree,vinayvinsol/spree,useiichi/spree,calvinl/spree,priyank-gupta/spree,locomotivapro/spree,richardnuno/solidus,TimurTarasenko/spree,DarkoP/spree,zaeznet/spree,degica/spree,tesserakt/clean_spree,welitonfreitas/spree,pervino/spree,vcavallo/spree,mindvolt/spree,mleglise/spree,cutefrank/spree,Arpsara/solidus,yushine/spree,yiqing95/spree,siddharth28/spree,softr8/spree,vmatekole/spree,jsurdilla/solidus,APohio/spree,Boomkat/spree,pervino/solidus,yiqing95/spree,gregoryrikson/spree-sample,CiscoCloud/spree,ahmetabdi/spree,moneyspyder/spree,nooysters/spree,ayb/spree,odk211/spree,bricesanchez/spree,builtbybuffalo/spree,azclick/spree,ahmetabdi/spree,vulk/spree,edgward/spree,locomotivapro/spree,siddharth28/spree,richardnuno/solidus,archSeer/spree,derekluo/spree,yushine/spree,njerrywerry/spree,priyank-gupta/spree,grzlus/spree,groundctrl/spree,odk211/spree,gautamsawhney/spree,joanblake/spree,thogg4/spree,firman/spree,Ropeney/spree,DarkoP/spree,zamiang/spree,karlitxo/spree,JDutil/spree,trigrass2/spree,scottcrawford03/solidus,carlesjove/spree,jspizziri/spree,vcavallo/spree,NerdsvilleCEO/spree,Arpsara/solidus,gautamsawhney/spree,Engeltj/spree,keatonrow/spree,firman/spree,adaddeo/spree,FadliKun/spree,groundctrl/spree,Ropeney/spree,lsirivong/spree,derekluo/spree,KMikhaylovCTG/spree,ujai/spree,jaspreet21anand/spree,ramkumar-kr/spree,TimurTarasenko/spree,tesserakt/clean_spree,trigrass2/spree,sfcgeorge/spree,devilcoders/solidus,locomotivapro/spree,CiscoCloud/spree,tesserakt/clean_spree,alejandromangione/spree,tancnle/spree,moneyspyder/spree,jparr/spree,bricesanchez/spree,quentinuys/spree,grzlus/spree,agient/agientstorefront,Senjai/solidus,Machpowersystems/spree_mach,piousbox/spree,njerrywerry/spree,siddharth28/spree,shaywood2/spree,jeffboulet/spree,volpejoaquin/spree,imella/spree,archSeer/spree,alejandromangione/spree,richardnuno/solidus,quentinuys/spree,jparr/spree,dandanwei/spree,reidblomquist/spree,beni55/spree,sideci-sample/sideci-sample-spree,reidblomquist/spree,omarsar/spree,raow/spree,net2b/spree,ckk-scratch/solidus,jimblesm/spree,vulk/spree,siddharth28/spree,Lostmyname/spree,edgward/spree,pulkit21/spree,athal7/solidus,Machpowersystems/spree_mach,nooysters/spree,Ropeney/spree,AgilTec/spree,TrialGuides/spree,jasonfb/spree,TrialGuides/spree,Hawaiideveloper/shoppingcart,forkata/solidus,TimurTarasenko/spree,imella/spree,reinaris/spree,zamiang/spree,alvinjean/spree,CJMrozek/spree,orenf/spree,Lostmyname/spree,JuandGirald/spree,builtbybuffalo/spree,Boomkat/spree,piousbox/spree,DynamoMTL/spree,adaddeo/spree,radarseesradar/spree,piousbox/spree,SadTreeFriends/spree,ayb/spree,rbngzlv/spree,tomash/spree,DarkoP/spree,madetech/spree,lsirivong/spree,pervino/solidus,pervino/solidus,rakibulislam/spree,Migweld/spree,xuewenfei/solidus,madetech/spree,azclick/spree,KMikhaylovCTG/spree,fahidnasir/spree,Hawaiideveloper/shoppingcart,carlesjove/spree,grzlus/solidus,tancnle/spree,patdec/spree,devilcoders/solidus,rajeevriitm/spree,bonobos/solidus,ayb/spree,pervino/spree,jspizziri/spree,vmatekole/spree,shaywood2/spree,sunny2601/spree,softr8/spree,kewaunited/spree,berkes/spree,patdec/spree,camelmasa/spree,keatonrow/spree,caiqinghua/spree,builtbybuffalo/spree,grzlus/spree,brchristian/spree,PhoenixTeam/spree_phoenix,firman/spree,groundctrl/spree,robodisco/spree,surfdome/spree,builtbybuffalo/spree,assembledbrands/spree,zamiang/spree,Kagetsuki/spree,archSeer/spree,caiqinghua/spree,beni55/spree,carlesjove/spree,jordan-brough/solidus,reidblomquist/spree,lsirivong/spree,vinayvinsol/spree