text:
Q: AttributeError: 'list' object has no attribute 'lower' error when trying to fit a 2d array Im trying to train a model to detect fake news and am trying to make a bag of words model. However when I try to fit my model i get this error:
Traceback (most recent call last):
  File "/Users/amanpuranik/PycharmProjects/covid/fake news 2.py", line 89, in <module>
    headline_bow.fit(lower)
  File "/Users/amanpuranik/PycharmProjects/covid/venv/lib/python3.7/site-packages/sklearn/feature_extraction/text.py", line 1186, in fit
    self.fit_transform(raw_documents)
  File "/Users/amanpuranik/PycharmProjects/covid/venv/lib/python3.7/site-packages/sklearn/feature_extraction/text.py", line 1220, in fit_transform
    self.fixed_vocabulary_)
  File "/Users/amanpuranik/PycharmProjects/covid/venv/lib/python3.7/site-packages/sklearn/feature_extraction/text.py", line 1131, in _count_vocab
    for feature in analyze(doc):
  File "/Users/amanpuranik/PycharmProjects/covid/venv/lib/python3.7/site-packages/sklearn/feature_extraction/text.py", line 103, in _analyze
    doc = preprocessor(doc)
  File "/Users/amanpuranik/PycharmProjects/covid/venv/lib/python3.7/site-packages/sklearn/feature_extraction/text.py", line 68, in _preprocess
    doc = doc.lower()
AttributeError: 'list' object has no attribute 'lower'

Im not sure why im getting this error. This is the dataset im trying to fit:
[['four', 'way', 'bob', 'corker', 'skewer', 'donald', 'trump'], ['linklat', "'s", 'war', 'veteran', 'comedi', 'speak', 'modern', 'america', ',', 'say', 'star'], ['trump', ''', 'fight', 'with', 'corker', 'jeopard', 'his', 'legisl', 'agenda']]

Here is the rest of my code:
data = pd.read_csv("/Users/amanpuranik/Desktop/fake-news-detection/data.csv")
data = data[['Headline', "Label"]]

x = np.array(data['Headline'])
print(x[0])
y = np.array(data["Label"])

# tokenization of the data here'
headline_vector = []

for  headline in x:
    headline_vector.append(word_tokenize(headline))

print(headline_vector)

stopwords = set(stopwords.words('english'))

#removing stopwords at this part
filtered = [[word for word in sentence if word not in stopwords]
            for sentence in headline_vector]
#print(filtered)

stemmed2 = [[stem(word) for word in headline] for headline in filtered]
#print(stemmed2)

#lowercase
lower = [[word.lower() for word in headline] for headline in stemmed2] #start here

#organising
articles = []

for headline in lower:
    articles.append(headline)

#creating the bag of words model

headline_bow = CountVectorizer()
headline_bow.fit(lower)
a = headline_bow.transform(lower)

why is this happening and what can I do to fix this?

A: I will guess.
Documentation for CountVectorizer shows it has to be list of strings (1-dimensional list) but you have list of lists of word (2-dimensional list)
You may have to convert evey list of words to string (sentence)
lower_sentences = [" ".join(x) for x in lower]

and then you can use it
headline_bow = CountVectorizer()
headline_bow.fit(lower_sentences)
a = headline_bow.transform(lower_sentences)

Working example
from sklearn.feature_extraction.text import CountVectorizer

lower = [['four', 'way', 'bob', 'corker', 'skewer', 'donald', 'trump'], ['linklat', "'s", 'war', 'veteran', 'comedi', 'speak', 'modern', 'america', ',', 'say', 'star'], ['trump', ''', 'fight', 'with', 'corker', 'jeopard', 'his', 'legisl', 'agenda']]

lower_sentences = [' '.join(words) for words in lower]

headline_bow = CountVectorizer()
headline_bow.fit(lower_sentences)
a = headline_bow.transform(lower_sentences)

redpajama_set_name: RedPajamaStackExchange


Tutti Frutti Farm now has over 400 acres of organic heirloom tomatoes, specialty cherry tomatoes, a variety of sweet and hot peppers, zucchini and winter squash. Tutti Frutti is situated in beautiful Santa Barbara wine country near California's Central Coast. The location, climate, and the farm's dedication to long-range sustainability all come together to produce a consistently delicious crop.


text:
Detroit Tigers Rumors
Kyuji Fujikawa granted free agency in Japan, will pitch in MLB in 2013; could Tigers be interested?
The Tigers haven't historically pursued Japanese free agents, but Kyuji Fujikawa might be the perfect fit to bolster their bullpen for the next few years.
By Rob Rogacki@BYBRob Nov 15, 2012, 8:02am EST
Share All sharing options for: Kyuji Fujikawa granted free agency in Japan, will pitch in MLB in 2013; could Tigers be interested?
Former Tiger, future Tiger?
Rick Osentoski-US PRESSWIRE
Kyuji Fujikawa was the biggest name of four Japanese players to be granted free agency yesterday in hopes of signing with MLB teams before the 2013 season. I hadn't even heard of him until one of our readers sent us a message about it -- see, we do listen to your input! -- but after looking at his numbers, he looks like a great fit for the Tigers.
Fujikawa is a 32 year old right-hander who has spent the last six-plus seasons as the closer for the Hanshin Tigers -- oh, the parallels here -- in the Japanese League. His fastball typically sits between 92-94 mph, but can top out anywhere from 95-97 mph depending on which scouting report you find when you Google him. His numbers as a closer are pretty similar to those of Yu Darvish, the former Nippon Ham Fighter who finished second in the AL Rookie of the Year voting this season. Fujikawa was 26-18 with a 1.36 ERA and 202 saves in 369 2/3 innings since the start of the 2007 season.
His peripherals are off the charts. He strikes out 12.4 batters per 9 innings while walking just 2.3 per 9 innings. His career WHIP is just 0.855 and he allowed an average of 10 runs per season (!) during his last six years in Japan. His numbers dipped a bit in 2012, but there's only so much complaining allowed when your closer goes 2-2 with a 1.36 ERA and saves 24 games. He pitched in 48 total games, but since he only allowed seven runs all season, I'm willing to bet that many of those appearances were in non-save situations. Another plus: he doesn't give up runs in situations that Jose Valverde normally would have.
Why should we stay away?
There's always a huge concern with Japanese players transitioning to the MLB, and we don't have much history to draw on for a bullpen guy like Fujikawa. Hideo Nomo is the only Japanese-born pitcher to have any sustained success in the majors, though Darvish may be joining that list in a few years. There are many other cautionary tales -- Kei Igawa comes to mind -- and generally the large contracts doled out to these guys are worth well more than their actual production. It's probably a safe bet to say that Fujikawa won't command Darvish's asking price, but I'd imagine that it will be more than the Tigers brass wants to spend on a closer next season.
Will he end up in Detroit?
It's fun to think so, but I doubt it. I'm less skeptical of Fujikawa's ability to translate to the American game after the seasons that both Darvish and Wei-Yin Chen had in 2012, but it's also tough to gauge whether a guy like Fujikawa can get outs in the majors without a decent secondary pitch -- seriously, I haven't found anything mentioning a slider, curveball, or changeup whatsoever. I doubt that the Tigers will start looking at Japanese players now after having success without dipping into Asia's ever-increasing talent pool, especially when there are other options available stateside.
Detroit Tigers offseason targets: Who should the Tigers be keeping a close eye on?
Tigers Offseason Target: Edwin Jackson
Tigers Offseason Target: Kyuji Fujikawa
Tigers Offseason Target: Ichiro Suzuki

redpajama_set_name: RedPajamaCommonCrawl


text:
In de economische theorie is imperfecte concurrentie in een markt de competitieve situatie, waar niet aan de noodzakelijke voorwaarden voor perfecte concurrentie wordt voldaan. Het is een marktstructuur die niet aan de voorwaarden van perfecte concurrentie voldoet.

Vormen van imperfecte concurrentie zijn:
 Monopolie, waar sprake is van slechts één verkoper van een goed.
 Oligopolie, waar sprake is van een klein aantal verkopers.
 Monopolistische concurrentie, waarin er veel verkopers zijn die zeer gedifferentieerde goederen produceren.
 Monopsonie, waar er slechts één koper van een goed is.
 Oligopsonie, waar sprake is van een klein aantal kopers.
 Informatieasymmetrie, waar één concurrent het voordeel heeft van betere informatie dan de rest.

Er kan sprake zijn van imperfecte concurrentie als gevolg van een vertraging in de markt. Een voorbeeld is de "jobless recovery". Na een recessie zijn er vele groeimogelijkheden beschikbaar, maar het kost werkgevers tijd om te reageren, wat tot hoge werkloosheid leidt. Hoge werkloosheid doet de lonen relatief dalen, waardoor het inhuren van arbeid aantrekkelijker maakt, maar het kost tijd voordat er nieuwe banen worden gecreëerd.

Micro-economie

redpajama_set_name: RedPajamaWikipedia


NEW YORK, New York – June 13, 2017– Boost Payment Solutions, Inc., a New York-based FinTech serving the B2B payments arena, closed a round of funding from San Francisco-based Mosaik Partners.
Widely known as the leader in the nascent B2B payments arena, Boost provides corporations, institutions and municipalities with technology-enabled solutions that optimize commercial card usage and acceptance, making the migration of paper checks to electronic payments quick, easy and profitable for all stakeholders.
Boost Intercept®, the company's proprietary B2B gateway platform, transforms manual virtual card payments into a completely passive, straight-through processed experience for suppliers, while also benefitting buyers through rebates and operational efficiencies. Boost's B2B-specific reporting capabilities are unmatched in the acquiring ecosystem and allow enterprises that accept commercial card payments from corporate customers to seamlessly integrate remittance data into their own ERP platforms.
Boost is currently operational in the U.S., Caribbean, Canada, Europe and UAE and will be launching in Australia/New Zealand, Brazil and Hong Kong/Singapore/Malaysia later this year.
Proceeds from this funding will be used primarily to expand the company's organic growth strategies across all functional areas with a focus on business development, sales, product development and support.
Golding & Company served as exclusive strategic and financial advisor to Boost in this transaction.
Boost Payment Solutions is a global provider of B2B payment technologies that eliminate pain points often associated with the use and acceptance of commercial cards. The company's proprietary Boost Intercept® platform is the only gateway that automatically transforms e-mail based virtual card notifications into straight through processed payments, paving the way for expanded acceptance and incremental card-based spend for commercial card customers. Visit us at www.boostb2b.com.


text:
Still got a couple of bottles
Still got a couple of bottles of Wiser Deluxe (from Hiram Walker) sitting here in my closet. Windsor is a cool and eclectic history. Was a refreshing change, he said, to visit the city in the summer. The 114 mile long Penn East pipeline's promise is to bring cheap natural gas into New Jersey and parts of Pennsylvania, but Fisher says it would be at the expense of his 75 acre preserved farm."Hay can't grow over top of pipeline." Fisher added. The pipeline is set to go through 4,400 acres of preserved land. This material may not be published, broadcast, rewritten or redistributed..
The life insurance industry pointedly ignores the views of some Pro Smoking Pressure Groups which argue that smokers under the age of 40 have around the Discount NFL Jerseys same probability of dieing as non smokers. David Pickett, Life Insurance Manager at Sainsbury spoke for the insurance industry when he confirmed "Health risks associated with smoking can have a big effect on life cover costs. It is vital for those who have kicked the habit to review their policies".
"Then as a board member at Invacare, he signed off on a policy of outsourcing Ohio jobs the same year that he received a pay increase for his board work there" Smith said. "Now, http://www.jerseys2013.com/ he is asking Ohio voters to elect him to create jobs here in Ohio. If past is prologue, it's clear that he cannot be trusted to do that.".
Aleya Ghost Lights in West Bengal is one such place. The area is said to be haunted by a fisherman spirit, and the pattern of light is supposed to be an outline of his once existent body. Fisherfolk in the area believe the wisps are a sign of impending doom.
I can even give cheaper cigarettes info to those of you who smoke imported or superpremium brands. The same duty and tax free status applies, bringing the price of superpremiums down to equal the price of a pack of Camels. And not only will you save money on your Shermans, Gauloises and Gitanes, but you will also have the convenience of having them delivered to your door..
"This is something I've never thought of," supervisor Campbell said. "We're even more behind than I imagined. We don't know what we have, need, a cycle to replace it. Wasn sure of the repercussions and the reasons as to why this was happening, he said. Think over time people will come to realize that this was a very good decision for the aboriginal community that not only attends the school, but will attend the school or maybe has attended the school in the past. Said he was very pleased that students from all grades were able to have a say in the decision and among the student body, there was stronger opposition to changing the name than the logo.


text:
Cinemark Holdings (CNK) Q2 2019 Earnings Call Transcript
CNK earnings call for the period ending June 30, 2019.
Motley Fool Transcribing
(MFTranscribing)
Aug 3, 2019 at 12:23AM
Cinemark Holdings (NYSE:CNK)
Aug 02, 2019, 8:30 a.m. ET
Good day. My name is Shelby, and I'll be your conference operator today. At this time, I would like to welcome everyone to Cinemark's second-quarter earnings call. [Operator instructions] Thank you.
I would now like to turn the call over to Ms. Chanda Brashears, vice president of investor relations. Please go ahead, ma'am.
Chanda Brashears -- Vice President of Investor Relations
Thank you, Shelby, and good morning, everyone. At this time, I would like to welcome you to Cinemark Holdings Inc's. second-quarter 2019 earnings release conference call hosted by Mark Zoradi, chief executive officer; and Sean Gamble, chief financial officer and chief operating officer. In accordance with the safe-harbor provision of the Private Securities Litigation Reform Act of 1995, certain matters that are discussed by members of the management team during this call may constitute forward-looking statements.
Such statements are subject to risks, uncertainties and other factors that may cause Cinemark's actual performance to be materially different from the performance indicated or implied by such statements. Such risk factors are set forth in the company's SEC filings. The company undertakes no obligation to publicly update or revise any forward-looking statements. Today's call and webcast may include non-GAAP financial measures.
A reconciliation of these non-GAAP measures to the most directly comparable GAAP financial measures can be found in today's press release, within the company's quarterly filing on Form 10-Q or on the company's website, investors.cinemark.com. I would now like to turn the call over to Mark Zoradi.
Mark Zoradi -- Chief Executive Officer
Thank you, Chanda, and good morning, everyone. Thank you for joining us to discuss our 2019 second-quarter results. We're thrilled to report that during the second quarter, we delivered all-time quarterly highs in global revenue, net income, adjusted EBITDA and earnings per share. These achievements were propelled by the strength across our global circuit.
A few noteworthy highlights include: domestic year-over-year box-office results that surpassed the North America industry by over 300 basis points and extended our outperformance trend to 37 of the past 42 quarters; double-digit domestic food and beverage per cap growth of 11%, which produced another new all-time high per cap; a 17% increase in international attendance, which surged over 30 million patrons, our highest quarterly international attendance since we sold our Mexico operation in 2013; and a 49% increase in international adjusted EBITDA. We achieved all these results by capitalizing on the second-quarter strong film lineup, as well as continuing to execute our customer-oriented strategic initiatives. These initiatives center on the guest comprehensive entertainment experience which include: providing top-notch customer service and amenities; enhancing the quality and variety of our food and beverage offerings; and strengthening our targeted and personalized interaction with guests both within and beyond our physical theaters. To provide a better picture, let's dig into the status of several of our key initiatives, starting with Cinemark Movie Rewards.
During the second quarter, we completed the rollout of a modification to the structure of our domestic loyalty program. That modification involved enhancing and combining Movie Fan, our free loyalty tier, along with Movie Club, our paid subscription tier, under a singular Movie Rewards umbrella. Following this change, we have already seen a significant uptick in new enrollments to our free Movie Fan program, with nearly 725,000 new sign-ups during the second quarter, which extends our global loyalty outreach to over 10 million members for whom we are developing more personalized and unique guest experiences to support current and upcoming film content. Meanwhile, growth in results of our paid Movie Club tier continued to exceed our expectation.
Since our prior earnings call in May, Movie Club membership has grown in excess of 20% to a cumulative 800,000 members. This figure equates to more than 2,300 members per theater location. Program satisfaction remains exceptionally high and members continue to cite Movie Club's benefits, value and convenience as key drivers, which include: the ability to roll over unused movie credits; a 20% food and beverage discount; waived online fees; add-on tickets for companions, as well as the ability to share unused movie credits; and a straightforward monthly membership that doesn't require a long-term commitment. Since we launched Movie Club about a year and a half ago, we have sold over 24 million movie tickets through the program.
And during the second quarter alone, Movie Club represented 14% of our domestic box office, spanning all genres and sizes of film. In fact, we saw an uptick in movie credit redemptions during the quarter from 75% to 80%, which is attributable to the strong appeal of the second-quarter film slate, the seasonality of summer moviegoing and Movie Club's ease of use. A fundamental objective of Movie Club is to stimulate incremental theater visits for both frequent and occasional moviegoers, which we are witnessing in our ongoing industry box-office and attendance outperformance, the high sustained utilization of the program observed through credit redemption and the fact that 75% of our members report that they are attending our theaters more frequently since joining Movie Club. Importantly, this stat has held consistent since we launched the program.
Similarly, in addition to incremental trips to the theater, over half of our members report that they are visiting our concession stand more often and are purchasing more products during each visit. We see this behavior validated in the transactional basket size for members that are comparable to nonmembers even though Movie Club's 20% discount, as well as our ongoing domestic per cap growth that is up over 12% year to date. So we're thrilled with Movie Club's continued growth and overall results. When we evaluate our domestic circuit's ongoing box-office performance, sustained ticket price growth and all-time high food and beverage per caps, we see Movie Club along with other key strategic initiatives as a meaningful contributor to our success.
Another key success factor in our expansion and enhancement is our expansion and enhancement of food and beverage offerings, which has led to 50 consecutive quarters year over year in domestic per cap growth. While this quarter's results were super charged by a mix of film content that played right to the sweet spot of concession buyers, our team's many efforts to stimulate incremental consumption was the core driver of sustained growth. Examples of these efforts include: a continued focus on driving core popcorn, fountain drinks and candy volume; our expanded -- our expanding Pizza Hut partnership; new alcohol activations; growth in multicultural fair; new and increased volumes of merchandise; and strategic concession stand designs that encourage incremental impulse purchases and accelerate throughput, to just name a few. We are extremely pleased with the tremendous success our food and beverage and theater operation teams have delivered, and we're continuously experimenting with deploying new innovations to sustain this growth trend into the future.
Two more initiatives that are enhancing our guest experience and also driving growth are the investments we've made in Luxury Lounger recliner seats at our XD premium large-format auditoriums. Luxury Loungers are now featured in 58% of our total domestic theaters, which has the highest penetration among the major exhibitors. Our theaters that have been repositioned with recliner seats continue to yield sizable benefits and customer satisfaction, as evidenced by direct feedback from our guests, as well as the willingness to drive further to enjoy this amenity. Furthermore, we continue to realize sustained list and attendance, ticket pricing and concession purchases at these locations.
As we look forward to the rest of the year, we still anticipate approximately 60% of our domestic circuit will be reclined by year-end. Cinemark XD also continues to deliver outsized results, as guests upgrade to the ultimate premium moviegoing experience it provides with immersive sight and sound technology. In the second quarter, XD generated approximately 10% of our global box office on only 4% of the screens. Moreover, XD achieved a new record, generating more than $50 million in worldwide admission revenue during the second quarter.
XD remains the No. 1 exhibitor branded premium large-format in the world with 263 XD auditoriums across our global platform. Overall, our ongoing efforts to enhance our guest comprehensive entertainment experience were a key ingredient to this quarter's strong financial and operating performance. Before I turn the call over to Sean, I'd like to take just a moment to provide some additional context regarding the overall exhibition industry.
There has been quite a bit of negativity in the news regarding the North America industry's second-quarter box-office results on account of a slight decline from last year and some overinflated expectation. What seems to have been overlooked is the fact that Q2 delivered the second highest grossing quarter of all time with $3.2 billion in box office, and a big reason for the modest decline is because 2Q of last year generated the highest grossing quarter of all time with $3.3 billion in box office. Furthermore, while certain films may have disappointed relative to lofty expectations, others overperformed and delivered stronger results than anticipated. We've seen this time and again that film performance is -- predominantly boils down to the quality and timing of each individual film.
That phenomenon clearly played out this quarter in Latin America. After several quarters of challenging content mix that didn't resonate well with Latin audiences, as well as other places in the world, the second quarter experienced tremendous attendance growth across the region. In fact, Avengers: Endgame became the highest grossing film of all time in Latin America, similar to the rest of the globe, and Toy Story 4 became the highest grossing animated film of all time. Second-quarter growth throughout Latin America underscores the notion that box office more closely correlates to film content than economic or political cycles.
As for the remainder of 2019, we remain enthusiastic about the upcoming film lineup. The third quarter kicked off with a bang as Spider-Man: Far From Home and The Lion King have both delivered over $1 billion in global box office. We've also had strong openings from last weekend's Once Upon a Time in Hollywood and Hobbs & Shaw last night, and we look forward to the much anticipated sequel to It, still to come. We expect third-quarter Hollywood content will also perform well in Latin America, which will be -- which will further benefit from part two of the Brazilian local title Nada a Perder.
In the second quarter last year, part one of Nada a Perder generated over 12 million in attendance, with similar results anticipated for part two. The fourth-quarter slate also looks promising, with Frozen 2, Star Wars: The Rise of Skywalker, Jumanji 2, Ford v. Ferrari, A Beautiful Day in the Neighborhood and Joker, just to highlight a few. I'd like to remind you that both Frozen 2 and Jumanji 2 will not be released this year in our key Latin American territories.
Instead, they're scheduled for January of 2020 to take advantage of school holidays consistent with historical release patterns. So again, considering the exacerbated media coverage regarding the box office this year, we thought it would be helpful to provide that slight drill down into the second, third and fourth quarters. That said, we continue to encourage you to take a longer-term view when analyzing box office and attendance trends as it can be easy to misinterpret the big picture when only focusing on specific films, weekends, quarters or even individual years. North America industry attendance has held steady at approximately 1.3 billion patrons per year, going all the way back to 2010.
And that's during mass adoption of over-the-top streaming services in the home for the past seven and a half years and excludes the full benefit that the industry is starting to realize from its many recent investments in recliner seats, new food and beverage concepts, subscription services and advanced data and marketing tools. Cinemark operates and excels within this stable industry, and we believe some of our key distinguishing factors are our overall financial strength, our operating and investment discipline, the consistency of our results and an ongoing focus on creating long-term shareholder value. Our front-line theater teams around the world are dedicated to providing our guests a truly memorable moviegoing experience in the highest quality out-of-home environment which will generate loyal patrons and continue to deliver consistent results. That concludes my prepared remarks.
I'll now turn the call over to Sean to address a more detailed discussion of our second-quarter financial performance. Sean?
Sean Gamble -- Chief Financial Officer and Chief Operating Officer
Thank you, Mark. Good morning, everyone. Before diving into the details of our second quarter's financial results, I'd like to remind you once again, that as of January 1, 2019, we have fully lapped our transition to ASC 606's revenue recognition accounting standards that took place over the course of 2018. And as discussed last quarter, beginning this year, we implemented accounting pronouncement ASC 842 which impacts lease accounting.
Associated with the adoption of ASC 842, we recorded a new operating lease right-of-use asset and a corresponding right of lease liability of approximately $1.5 billion each. Additionally, a small subset of capital leases have now been converted to operating leases according to the new standards. The transition to ASC 842 has zero impact on net cash flow and minimal impact on net income. However, it does create a slight nonoperational drag on our adjusted EBITDA and operating cash flow metrics.
Additional information about these changes can be found in the footnotes of our 10-Q or in the 8-K we filed on May 7, 2019, in tandem with our first-quarter earnings release. It's important to emphasize that ASC 842 is purely an accounting presentation change, which is largely intended to reflect all lease obligations on the balance sheet. It does not impact cash rent payments, obligations to landlords or any other underlying business or operating fundamentals. Shifting now to our second-quarter financials.
As Mark described, during the quarter, our global company generated all-time quarterly records in total revenues of $957.8 million and consolidated adjusted EBITDA of $244.7 million. Furthermore, our adjusted EBITDA margin reached a second-quarter high of 25.6% even though it was reduced by 60 basis points as a result of the ASC 842 accounting presentation changes. In the U.S., admissions revenues of $407 million were relatively in line with last year's record-setting result and declined by only 0.5%. As Mark already mentioned, this result surpassed the North American industry box office by over 300 basis points and was driven by outperformance in both attendance, which declined 1% to 50.1 million patrons; as well as ticket price, which increased 0.5% to $8.12.
While a higher mix of child tickets and reduced 3D associated with this year's heightened volume of family films created a drag on our average ticket price, overall ATP growth came from strategic increases in core prices, as well as incremental opportunities from recliner conversions. Despite the modest attendance decline during the quarter, total domestic concession revenues grew 10.1% to $274.9 million. This growth can be attributed to our ongoing actions and promotions that are geared toward stimulating incremental consumption, as well as the slate of films that worked particularly well with the most active concession consumers. Collectively, these factors drove concessions per patron up 11.4% versus 2Q '18 to another new all-time high of $5.49.
Similarly, domestic other revenues also grew and were up 21% versus last year, predominantly as a result of increases in promotional and transactional-related income. Overall, our U.S. circuit delivered all-time highs in both total revenues of $743 million and adjusted EBITDA of $195.3 million with an adjusted EBITDA margin of 26.3%. Internationally, admissions revenues were $114.1 million, which increased 14.1% versus last year as reported and 36.2% in constant currency.
International attendance grew 16.7% to 30.1 million patrons, spurred by the favorable film content drivers that Mark addressed earlier. Our reported average ticket price of $3.79 translated to a constant-currency increase of 16.5% that resulted primarily from inflationary price growth, as well as an anomaly that lowered last year's overall average pricing associated with the local title Nada a Perder. International concessions revenues were $70.4 million, which increased 26.4% as reported and 48.1% in constant currency. Our as reported international concessions per patron was $2.34 and grew 26.9% in constant currency as a result of inflation, our strategic food and beverage initiatives and a similar impact that Nada a Perder had on last year's per cap results.
International other revenues were $30.3 million, which increased 24.7% as reported and 52.3% in constant currency. This increase was largely driven by favorable growth in screen advertising and promotional income. Overall, total international revenues grew 19.3% to $214.8 million as reported. Adjusted EBITDA increased 49% to $49.4 million, and our adjusted EBITDA margin was up 460 basis points to 23%.
As expected, foreign currency translation remained a headwind in the second quarter, leading to an approximate 17% drag on our reported financials. And while future currency fluctuations are difficult to predict, if current rates continue to hold, we would expect percentage headwind in the mid-single-digit range for the second half of the year. As a reminder, the vast majority of our international operating expenses are transacted in local currency, including film rental and facility lease payment expenses. So the impact of currency exchange is predominantly translation-based and not transaction-oriented.
Shifting back to our worldwide consolidated results. Second-quarter film rental and advertising costs as a percentage of admissions revenues increased slightly by 20 basis points to 56.6% in comparison to the prior year. Likewise, concession cost as a percentage of total concessions revenues increased by 150 basis points, predominantly as a result of product mix associated with expanded food offerings, as well as merchandise opportunities that benefited from the second quarter's enhanced character-driven lineup of films. As mentioned on prior calls, while these newer offerings tend to create a slight drag on our concessions margin rate, they continue to drive sizable growth in overall concessions revenues and income.
Salaries and wages were 11.4% of total revenues and increased slightly by 10 basis points compared to the second quarter of 2018, predominantly driven by wage inflation and incremental hours to support our varied concessions initiatives. Facility lease expenses as a percentage of total revenues increased by 20 basis points primarily due to new theaters and a $5.7 million year-over-year presentation change associated with the adoption of ASC 842. Conversely, utilities and other costs as a percentage of total revenues declined by 20 basis points as did G&A. Collectively, second-quarter pre-tax income was $140 million.
Our second quarter's effective tax rate was 27.3%, and net income attributable to Cinemark Holdings Inc. was $101 million or $0.86 per diluted share. With respect to our balance sheet, we ended the quarter with a cash balance of $511 million and a net debt position of $1.4 billion. Our net debt improved by $107 million versus prior year as a result of reclassifying certain capital lease obligations to operating lease obligations connected to the new lease accounting guidelines.
Turning attention to our U.S. footprint. We operated 344 theaters and 4,630 screens in 41 states and 102 DMAs at quarter end. During the quarter, we opened two theaters and 24 screens, acquired two theaters and 30 screens and closed two theaters with 20 screens.
We have signed commitments to open two theaters and 24 screens during the remainder of 2019 and nine theaters representing 102 screens subsequent to 2019. We expect to spend approximately $90 million in capex associated with these 126 screens. Internationally, we operated 205 theaters and 1,456 screens in 15 countries across Latin America. As of quarter end, we have signed commitments to open six new theaters and 49 screens during the remainder of 2019 and eight theaters representing 60 screens subsequent to 2019.
We anticipate spending approximately $62 million in capex for these 109 screens. Consistent with our prior comments, we continue to view Latin America as a long-term growth opportunity, and we anticipate adding, on average, 50 to 75 international screens per year in the near term. Regarding overall capex, we spent $57.6 million in the second quarter including $14.2 million on new builds and $43.4 million on existing theaters that was predominantly associated with recliner conversions and other revenue-generating investments. For the full year, we continue to anticipate spending between $300 million to $325 million of capex, of which approximately a third is designated for new builds both domestically and internationally, another third is for core maintenance including certain expenditures to satisfy varied regulatory requirements, and the remaining third is budgeted for cash flow generating projects that include additional Luxury Lounger theater conversions and varied food and beverage initiatives that meet our balanced and disciplined investment thresholds.
We continue to expect annual depreciation and amortization will remain roughly in line with 2018 at approximately $260 million to $270 million as incremental growth associated with new capital expenditures is largely offset by the impact of ASC 842. In closing, we are thrilled with the many all-time high record results we generated during the second quarter. Furthermore, we are highly encouraged by the continued progress of our strategic initiatives that helped deliver this record performance along with the sustained pipeline of promising film content ahead. We remain focused on making prudent investments to position ourselves for ongoing success and to deliver long-term shareholder value while maintaining the financial health of our company.
Shelby, that concludes our prepared remarks, and we would now like to open up the lines for questions.
[Operator instructions] Your first question comes from Eric Handler of MKM Partners.
Eric Handler -- MKM Partners -- Analyst
Thank you very much, and good morning. Two questions for you, guys. First, with alcohol sales, what percentage of your theaters now sell alcohol? And where can that go to over the next couple of years? And I'll have a follow-up after.
Eric, thanks for the question. Eric, we're just under 50% now, about 45%. By year-end, we'll be at about 50% of our theaters offering alcohol, some beer, wine and frozen others with a full bar. We'll continue to grow that.
It's not going to -- there's not a real steep addition to that because there are certain parts of the country that we operate in where we won't -- we'll likely not to add alcohol, for example, in most of Utah, parts of Idaho where we won't. Other places have very restrictive alcohol policies like the state of Washington. Some places, alcohol licenses are just prohibitively expensive, for example, some of the East Coast states. So we'll be at 50% by the end of the year, and we'll continue to grow that in a modest way going forward.
Great. And now that you're increasing your free -- the Movie Fan tier of customers, and you got good growth there, you're up to 800,000 subs for Movie Club, can you talk about some of your push marketing initiatives, and how that's been changing over the last couple of years, and what you're capable of doing now with going through big data?
Well, let me start with Movie Fan which you asked about first. Movie Fan, we think, has got tremendous growth opportunities since we just really relaunched this with our new format. We think over the next two, three, four quarters, that we'll see that number continue to grow significantly, domestically as well, as we'll continue to add loyalty programs throughout Latin America. Some countries have them, some don't right now.
From a Movie Club standpoint, we have been very aggressive in marketing, acquiring a lot of our subs from our existing members in our loyalty program but also reaching beyond our walled garden with promotions, with everyone from Coca-Cola Company to AT&T, to Amazon, to Costco. So there is a strong marketing group on our team dedicated to loyalty who will continue to market Movie Club. The way that we design Movie Club in the beginning was to appeal to a very, very broad audience of moviegoers. So most moviegoers in the United States go somewhere between six and 12 times a year.
Obviously, there's some people that don't go at all. But if you're a moviegoer, that's your general -- that's the big audience. And so we designed Movie Club to really be able to attract those people, make it very economically viable for them and the best value. And I think that's why we've seen this consistent growth in Movie Club.
And we think we still have a quite a runway to go on that.
Great. Thank you very much.
Thanks, Eric.
Your next question comes from Alexia Quadrani of JP Morgan.
Alexia Quadrani -- J.P. Morgan -- Analyst
Thank you so much. Just two questions. First, just looking at the outperformance in the quarter. Any sense how much was sort of driven by the strategic initiative that you went through versus really just the type of film that may have played better at given where you're located -- where your theaters are located? And then the second question, I just wanted to thank you for the commentary you gave around the overall health of the box office and the concerns around the second-quarter industry performance.
I guess staying on that topic, I would love to hear if you think that there's some truth in what people are saying about maybe just too many sequels and maybe comedy's just really very, very hard to make work.
Thanks for the questions, Alexia. This is Sean. I'll take the first question, and Mark will do the second. Regarding our outperformance, I would say it's hard to precisely segregate how much came from each action we're doing, but I can tell you that we certainly see benefit continuing to be derived from our recliner performance.
We look at our recliner -- reclined theaters and our recently reclined theaters, we definitely saw some sizable outperformance relative to the industry for those theaters. Obviously, our ticket pricing also was higher than the industry on a whole, so we got some lift there. The content mix definitely did also help us. There's a lot of favorable family content which does well across our circuit.
And then we also have the benefits of Movie Club, which, as Mark mentioned in his prepared remarks, we continue to see stimulating moviegoing. So those are what we look at when we kind of drill into it as some of the driving forces of what led to our outperformance. I would say, the only other thing that we derived a small ticket benefit from is we had fewer close screens for reclining this year relative to last year when we were in a more active reclining mode.
Alexia, relative to your question on the box office and sequels, I would say no. I don't think there's too many sequels. I think it's a matter of what does the audience want and what are they willing to -- get out of their home and go pay their $10 to $12 to $13 to go see. And in the second quarter, there was really a mix of that.
Clearly, you had Avengers as dominating the second quarter and probably Toy Story 4, but those were highly satisfying movies. And Avengers was not only the massive box-office success but also a critical success and an audience pleaser, and the same goes with Toy Story 4. And then there was Yesterday, which was really a fresh new movie that performed very well. And as we look -- as we're looking at the quarter that we're in right now, you have Once Upon a Time in Hollywood, which has come out and done -- and has had a really good start; and then of course, Lion King, which is a CGI sequel follow-up to the original hit from the '90s, again, extremely audience satisfying.
So I think what the studios are trying to do is to try and look and say, what are people wanting to go see and what are they willing to generate the desire to leave the home and go out? And that's what they're providing. And whether that's a new movie or whether it's a sequel, I don't think that really matters. You look into the fourth quarter, boy, you got Ford v. Ferrari, A Beautiful Day in the Neighborhood, along with the sequel to Frozen.
So a couple of new and a couple of sequels.
Thanks, Alexia.
Your next question comes from Eric Wold with B. Riley.
Eric Wold -- B. Riley FBR -- Analyst
Thank you. Good morning. I'll avoid any asking any questions on domestic. As you all know, the industry is going nowhere.
So might as well go elsewhere.
By the way, we appreciate your comments, Eric, and what you've written.
So a couple of points on Latin America. You've obviously had weakness there in attendance for some time. Last year, you had the World Cup and the Brazil trucker strike in the second quarter. So I don't want to dwell too much on one quarter doing extremely well.
But are you starting to see anything in attendance or spending patterns down that would indicate that it was more just than an easy comp in Q2 as much as you're starting to see a pivot toward stronger trends in the region?
Eric, I think it's both things, as you said. I mean clearly, we had the trucker strike last year, so that was good relative to comparison. But the more important thing is that the movies just lined up well. There was a strong content of a family based product.
Toy Story did incredibly well in the United States. But you know what? It was the biggest animated movie of all time in Latin America. And in Argentina, not only the biggest animated movie, it was the biggest movie of all time, live action or animated. So when you have movies that really line up well with the desires of the people, that's the kind of thing you get.
And then of course, Aladdin did very well there as well, and Avengers did very well. So you had action/adventure and you had strong family content, and that's what we're really seeing going into the third quarter as well. So I think it's very much content-driven that drove the box office in Latin America.
And I'll just add to what Mark said. When we've kind of dug into some of the prior years, we've just seen softness in some of those core categories that really played to the live audiences in family and horror. Those clearly came back this year. The other thing too, in particular to last year, a lot of the films that helped drive the U.S.
box office and created this disconnect for Latin audiences, they just didn't resonate with Latin audiences. They were just -- they were very kind of U.S.-oriented or just non-Latin oriented and that kind of propelled it, whereas we've seen more of the types of mix that really speaks to that audience. So just to reinforce what Mark said, it boils down heavily to the playability of the film content in that market. And then there's the ebbs and flows of local content, too, where we saw Nada a Perder in the second quarter of last year.
We got the benefit of that coming back in the third quarter of this year. So that's also going to be something that's going to really help prop up the region as we turn into this quarter.
OK. And I know it's difficult down there given the variety of countries you operate in, but what are your thoughts on in Movie Club-like offering down there, some kind of heightened loyalty program? Is that something you think would work in that region?
Eric, we actually have a version of a Movie Club program currently up and running in Argentina. It's doing very well. And we are actively looking at doing other forms of a Movie Club subscription offer in our major territories down there. One thing that I learned a long time ago in the international business is there's a lot of right ways to do it.
So we're going to take the concept of Movie Club, and Argentina created their own version of it which is right for Argentina. And Brazil will adapt it at a little bit to make it right for Brazil as well. So we're already active and up and running in Argentina, and Brazil is not far behind.
Your next question comes from Jim Goss of Barrington Research.
Jim Goss -- Barrington Research -- Analyst
Good morning. First, I try not to say this very often but I thought those were impressive results especially in the context of challenging comps and the FX headwinds you're dealing with. But I would ask with the -- you addressed a little of one of my questions of the average attendance per year, I think, tends to be about three to four people, but you said in terms of moviegoers, more like six or 12. And since you're stimulating incremental attendance, I'm wondering where you think that six to 12 can head from the experience you've had.
And do you think you're fairly far along capturing the audience you think you got for the Movie Club itself?
Jim, I'll take the second part of the question first. I think we're probably at the very most in the middle innings. I think we still have a long ways to go with Movie Club. I mean we've continued to see strength literally each and every week and each and every month to grow it, and we've got significant marketing and promotional opportunities to continue to do so.
And we really have aimed at the big, broad audience of American moviegoers with the concept of Movie Club. So I think we still have a way to go.And your first question was --
The average moviegoer.
Yeah, average moviegoer. Yeah, I think we can continue to grow it. I mean we're seeing in the research that Movie Club members are telling us over and over again, we do regular research that they're going to the movies more often since becoming a Movie Club member. And we're seeing also that Movie Club members are going to upwards of three times more than non-Movie Club members.
So every time we can get a Movie Club member and somebody has credits on their phone that they pre-paid for, and they can get their tickets with no online fees, and they can bring a friend with them, if that friend's not a member and they get there and they can get a 20% discount, we're just -- we've made it frictionless for the audience. So we think that the incrementality of additional ticket sales were seen specifically between members and nonmembers and members reporting that they're in fact going more since becoming Movie Club members.
OK. And I'm also wondering on the concession per patron gains you've made, what are the key drivers, U.S. and international? And you were just talking about that a little bit, the impact of the Movie Club 20% discount on these metrics?
I'll take that. When you kind of break apart -- at least this quarter's growth in per cap, I'll speak to domestic, I'll concentrate on that, but it's basically directionally the same, Jim. We look at about -- about half of the per cap growth came from volume this quarter. About 35%, we kind of look at, came from new categories and distribution techniques, a lot of those new instance driving initiatives that we're pursuing and about 15% came from price.
A lot of the volume, and let's say even some of the support from the initiatives-based lift, was helped by what we talked about earlier on just the mix of content. That mix was really played well to concession buying, particularly with regard to merchandise. So we were able to lean into that heavily. So those are the things that have been kind of driving that both domestically, internationally.
We think this quarter is particularly boosted by just how well the content laid out. But as you've seen, we've had a pretty long track record of growing that per cap growth. Our CAGR has generally been in the 5% to 6% growth range, and that's something that while it's a tough hurdle, we'd like to think that that's probably a bit more of a sustainable range.
OK. And lastly, screen advertising in Latin America. You talked about that in the past that you're developing your own program. I wonder where you stand in that, judging by the comments you just made.
And to what degree are you able to involve competitors in terms of the numbers of relationships or number of screens?
Jim, relative -- our screen advertising company in Latin America is called Flix. It actually has been very successful. We're continuing to add independent theaters change as affiliates. We are the No.
1 screen advertising company from south of Mexico down, because we don't operate Mexico obviously. We also have gained Cinepolis as an affiliate in some of our southern continent countries. So the fact that we have not only Cinemark, where we're the dominant exhibitor in Argentina and Brazil and very strong in Chile, we've also added quite a few affiliates so that we are the No. 1 screen advertising company in Latin America.
I'll just add, a big driver of that other revenue growth, it's about 52% in constant currency for international is the effect of, what Mark just talked about, bringing those third parties into the Flix network where that gets reported in that line.
Your next question comes from Alan Gould of Loop Capital.
Alan Gould -- Loop Capital -- Analyst
Thank you for taking the question. I've got a few. First, on free cash flow and capex. CapEx is down 29% the first half of the year, yet the free -- the capex guidance has not changed, which implies capex is sort of close to what it was second half last year.
Just want to confirm that that is as back-end loaded this year as that implies.
On the capex, yeah, we still think that is the case. In some of our new builds, which that's -- those are heavy capex consumers, some of those have kind of shifted. It's something we continue to look at. There is the possibility for that to drift on the low end of that scale, perhaps a bit lower.
But at the time -- for the time being, we're still optimistic that most of those are going to fall in-year. But yeah, we just kind of look at things, it's definitely drifting toward the lower end of that range at the moment.
OK. And secondly, Regal has now opened or is about to open a movie club in the U.S. Do you think that has a big impact on you?
I mean look, anytime there's -- Regal's a good competitor, and we've had Movie Club in the marketplace for -- since December of 2017. It was the first exhibitor-sponsored subscription program. And there are some markets in which we compete head-to-head with Regal, not as many as AMC does. The Regal program is much more in line and similar to the AMC program than it is to Movie Club.
So anytime you have a competitor come out with a big marketing plan, of course, it's going to affect you a little bit, but I don't think it's going to be dramatic for the two reasons. One, it's a different program. It's really centered on the mega heavy moviegoer, those that are going three and four times a month. We're focused on the more general frequent moviegoers who go six to 12 times a year.
So I don't think it will have a big impact on us, but of course, it will have a slight impact in a couple of markets that we compete with.
OK. And my last question, Mark, I appreciate your industry comments. I know the strong -- the 4Q, looks like it has a strong lineup. But I'm just wondering, what do you think the impact of Disney launching its OTT service and what looks like the release of some of Netflix's larger firms in the fourth quarter will have on you and the industry in 4Q?
Alan, the one thing that we have seen over and over again is that people who watch a lot of television at home, whether it's streaming or network television, those people also are people who actually leave the house and enjoy out-of-home entertainment the most. So we think that Disney doing their Disney+ can be complementary to us. It's clearly what we see in the research. And so from a Netflix standpoint, really this is business as usual for Netflix.
They've got a couple of more high-profile films this year. But Netflix bread and butter is serialized television. And so we're not concerned about that because at the end of the day, people want to get out of their house and enjoy a social environment in which to see movies, and we've seen it very consistently. As mentioned, during all the streaming that's happened over the last five, six, seven years, whether it was Hulu, Amazon, Netflix, we've had a relatively consistent amount of attendance overall in the business.
So with all the improvements that we've made, and certainly our competitors have made in improving the moviegoing experience, we think that we're going to continue to operate in a relatively stable business. And Disney is going to be, I think, actually a good partner in continuing to promote the theatrical moviegoing experience. They have been the most consistent supplier for us, and they continue to tell us that that's going to continue into the future. It certainly is, as we look forward to years 2020, '21.
They've announced that they're going to have a Star Wars or an Avatar in each corresponding year, there's going to be a couple of Pixars, there's going to be Disney live action. So I think Disney is very, very much committed to the theatrical business and now they're getting into the direct-to-home business as well.
Your next question comes from Meghan Durkin of Credit Suisse.
Meghan Durkin -- Credit Suisse -- Analyst
Hi. Good morning. I have two questions for Mark. I appreciate your comments on Regal's new plan.
Can you just remind us maybe what you saw in the Movie Club subscriber trends when AMC launched in 2Q '18?
That's a good point. Yeah. OK.
And then I'll just get in my questions now. Can you talk a little bit about the impact you could see on the business long term from CEOs maybe releasing fewer movies over time? I think investors seem to be worried that Disney's cutting Fox out, but in that others that could reduce their output. So do you have any visibility on 2020 and how many films there will be in the market and over time where that will go?
OK. Megan, let me take the first one relative to effect on Movie Club when A-List came out. Actually, the data shows that we continue to grow right through the introduction of A-List. And I think one of the reasons why, goes back to, that it really is designed for a different moviegoing audience.
A-List or Unlimited are designed specifically for that mega moviegoer who wants to go two and a half to four each and every month, and that's a relatively small segment of the audience. The majority of people, like I said, go six to 12 times a year. And so we did not see a downturn in our growth pattern when A-List came up. So that tells us that we -- I don't think we're going to see it with Regal's plan as well.
Relative to the number of movies that are made, this is not a numbers game. I had the good fortune of -- I was at Disney when we were making 20 and 24 movies a year across all these multiple different labels, and we cut that. It was really either strategy to cut down the numbers of movies but concentrate on making really big high-profile movies. And we all seen what Disney and Alan Horn and the Iger team have been able to put forward.
So this is not a numbers quantity game. This is a quality game, and we continue to see that. And as we look to 2020, we think it's a good strong lineup. It's hard to call and put a box office to it at this point, but Pixar has announced two really strong movies, Onward and Soul.
Marvel's come out with Black Widow and Eternal. Disney's got three big live action movies plus an untitled Disney animation. And then you have Wonder Woman coming from Warner Brothers, and Fast and Furious from Universal, and Minions from Universal and the next Bond and the next Top Gun and Conjuring and Birds of Prey. So we're seeing here relatively early in 2020 and are optimistic.
The one thing that you just never know is you never know what that big breakout is going to be. Sitting in our chair, none of us would've called Black Panther to do $700 million and nor would have anyone called It to be the breakout hit that it was or even Wonder Woman to be the breakout hit that it was. So we have a pretty good insight into the ones that are coming, and we're optimistic about others because there's always one or two surprises. It just is the movie business.
Your next question comes from Robert Fishman of MoffettNathanson.
Robert Fishman -- MoffettNathanson -- Analyst
Good morning. I have one for Mark and one for Sean. Mark, any updated thoughts on implementing dynamic or variable ticket pricing initiatives at your theaters? Or are you just solely focused on the Movie Club at the moment?
We're looking at that. I can't tell you that -- I can't give you any plans for it, but we're looking at it. And it all depends on how you define dynamic pricing. Right now we have a very steep variable pricing model.
So that if you go on Friday and Saturday night, usually there's a little bump in the Friday and Saturday night price off of what it would have been on Sunday through Wednesday. So you could call that some form of dynamic pricing. We currently do it. And then obviously during the week, we also price lower on Tuesdays.
We give student discounts, we give senior citizen discounts. So there's a pretty steep variable pricing mode in order to get those who are price-conscious, the ability to get in and see the movie either on a Tuesday or earlier in the day. And if you want to come Friday or Saturday night, currently, you're already paying a little bit of a premium. And as we go forward, we will continue to look at more directly dynamic pricing.
But I'm not in a position to talk about or to announce anything forthcoming.
OK. Fair enough. And for Sean, can you talk about whether you're seeing any improvements on the new screen development in Brazil specifically?
Can you just clarify, Rob, what you said in development?
Sorry. So just in terms of the development pipeline in Brazil, how the economic backdrop is potentially improving.
Sure. Sure. I would say, we still have a healthy backlog of projects. And again, as you know, those are all tied to malls.
So it's really what's the backlog of mall development in the region. So that still exists. I wouldn't say we've seen a meaningful change thus far, driven by the economy in terms of those projects starting to ramp up significantly. So I think there's still a degree of developers in waiting mode just to kind of see how the health of the economy ultimately plays out.
So the projects are there, but I'd say it's still somewhat stalled just in terms of the development, particularly within Brazil.
Your next question comes from Ben Swinburne of Morgan Stanley.
Ben Swinburne -- Morgan Stanley -- Analyst
Thanks. Good morning. Hey, Mark, I was wondering if you guys have done -- I mean I'm sure you have, but if you want to share any data on kind of cohort analysis of the Movie Club trends since you've launched it? In other words, when you look at some of these KPIs that you guys focus on, like incremental visits or incremental attendance per member and basket size lift, what do those trend lines look like over the 18 months as you track people who come in the system? I'm just wondering if this selection bias that's sort of, those with the highest propensity to go more, joins first. Or if anything, maybe it's the opposite because you're getting better at it and better at marketing? Just any you can share there as we look at the sort of impact of this on your overall attendance continuing to grow? I would be interested in any insights that you could share.
Ben, let me do two things. One, and you didn't really ask about this and I'm not going to give you a specific number, but I do want to say I think one of the real standouts for Movie Club, and I think it's because of the rollover aspect where you never lose the benefit of it, so if you don't use it for a month or two, they build up. So their -- our sustainability has been very, very high with a very low churn rate, lower than what you would expect for this kind of program. We're not disclosing that exact amount but you can just take it that it's significantly on the low side.
Relative to a metric that I think is also very important in the whole concept is people join the club for a variety of reasons. Some people, because of the rollover; some people because they don't want to pay online ticket fees; but some people, because they want the concession discount. And when we researched Movie Club, we researched 10%, 15%, 20%, 25%. And at the 20%, that's when it became a needle-mover, and that's when people -- it really became important to them.
So that's what we did. We knew we were taking a risk, but what we found is that the basket size of a Movie Club member versus a non-Movie Club member is about the same. So that means, by definition, Movie Club members are spending 20% more because they're getting the 20% discount. And then the thing that's really made it payoff is that the number of people that are going to the concession stand has increased.
So we have a higher incident rate with Movie Club members. So net-net, it has turned out to be a positive not only on attendance but net-net a 20% discount has turned out to be positive on food and bev as well. So I think those, kind of, are couple of the things you are looking for that are really critical in the success and why we're so enthusiastic about what can come in the future as well.
That makes sense. And just following up into your industry comments, Mark, I know you said it's not a numbers game and appreciate that. But I couldn't help but notice an interview with John Stankey this week where he talked about actually taking Warner Brothers output up to 30 films potentially a year. I didn't know if that sounded familiar to you, who know a lot more about their plans that we do.
I'd just be curious if everyone's been talking about Disney potentially shrinking Fox, but there's also been a big change at Warner's with a new CEO. I'm curious if you have any insights you maybe want to share there. And then I have to ask at least if you have any plans to distribute The Irishman in the -- later this year since that's obviously, as you have mentioned, a high-profile film that wanted some distribution.
I really can't speak about Warner Brothers' strategy because I don't have any particular insight there. I think the only thing that they have said is Warner Brothers has said that because they've got a lot of outlet and outlets -- that focusing on content and additional content for their multiple outlets is important to them. And by the way, Disney's doing the same thing. They may only be making 10 or 12 or 13 or 15 titles for theatrical, but they're going to increase their output for Disney+ the same way that Disney used to do direct to videos and direct to DVDs and direct to the Disney channel.
Disney is actually going to be increasing their output, it's just among various channels. So I think that in some ways, that's consistent. It's just how you add it up. As it relates to The Irishman, we would welcome to play The Irishman.
And we've stated that very congenial way multiple times to Netflix. The only issue, it comes down to, that Netflix is one potential supplier of theatrical motion pictures. And so the only thing we ask is that they play from a window standpoint consistent with our major suppliers, whether that be Disney or Warner Bros. AT&T or Comcast Universal.
So to the extent that they're willing to do that, we welcome them at all of our theaters.
[Operator instructions] Your next question comes from Chad Beynon of Macquarie.
Chad Beynon -- Macquarie Research -- Analyst
Good morning. Thanks for taking my question. Mark, Sean, clearly your strategy is industry-leading given the results that you continue to disclose here on a quarterly basis. And your loyalty program, as you've touched on today, appears to be working really well.
So does this make you think differently about M&A in the U.S. given your performance, the potential uplift you could have on other screens and in your current balance sheet, which might provide some capital to some theaters that haven't been able to roll out strategic initiatives like you have? Or is that just harder given that the boxes won't have your original DNA? Thanks.
Chad, we are literally every month open to M&A. Historically, we have been very disciplined buyers relative to M&A. And so to the extent that a family circuit came on the market -- or obviously, we're in contact with these people before they ever come on the market. And it can be purchased at a price that we're willing to pay, we're more than willing to do it.
But we don't see the strategic value of just rolling up if we have to pay a price that is at or above our current multiple. So we're very open to it not only in the United States but also in Latin America, and we've done some small acquisitions. But I don't think our strategy is going to change relative to being very disciplined buyers relative to the value of it. Sean, you may want to add something on that?
The only other thing I would add is along the same lines that Mark has told you, we also tend to prefer kind of quality assets. We find that rather than taking like a distressed asset and trying to apply some of our stuff to it, the challenge you get is you'll never know how deep those problems go and they can become a huge distraction to the larger portion of the business. So when we go after M&A, it's got to be a strategic fit. It's got to be financially accretive, and we generally are looking for things that are good assets.
So we continue to look for that. But I wouldn't say we materially are changing our view on M&A because of these types of programs. If anything, to the extent we do some, we did a small tuck-in this past quarter, and we'll apply those to it and we just like to think that it'll add some added benefit to it.
And then my follow-up, more short term. Just wanted to drill into the potential impact from Nada a Perder for the third quarter, which I believe is coming out in two weeks here. Can you see any advanced ticket purchasing? I don't know if that's readily available in that market. Just trying to understand the pressure on pricing for the third quarter and in international and potentially the pressure on margins because I believe in 2Q '18, there were a number of other things going on but there is definitely massive pressure on pricing and that kind of went down into the margin line as well.
I'll pick this up, and Sean may add some detail to it. This is a great opportunity for us. But along with that great opportunity, these tickets, many of them are actually purchased by the church entity for their members. And in doing so, they're buying them in big bulk group purchases.
So there is some lowering of price because they're being bought in such big quantities. And then also, when many of those people come, we see that the per caps weren't quite as high as per caps of normal moviegoers. So although the previous one did 12 million admissions, and we expect this one to be very successful as well, I don't know if it's going to be 12 million admissions, but we think it will be very successful especially in Brazil and also Argentina. There will be some lowering of the average ticket price on all those people.
And I would just -- just to give some context, obviously last year, we saw -- in constant currency, we saw price be a year-over-year modest negative as was concession per patron, largely driven by Nada. We think this current film could perform at similar levels to the prior film and we'll see. I'd say the other thing that, though, will help offset that is when we just look at the Hollywood content this year versus last year. We believe it has stronger potential.
So while Nada will clearly create a bit of a drag on certain metrics like pricing and concession, it may not be as steep as last year because of the overall performance we propped up by the Hollywood content. And keep in mind too, from a margin standpoint, while it creates a drag on those metrics, it adds a tremendous amount of attendance into the mix, which is very beneficial to the overall margins of the company.
The lineup for the third quarter for Latin America is strong: Spider-Man, Lion King, Hobbs & Shaw, It 2. So we're optimistic about the third quarter in Latin America.
Okay. Thank you very much, and congrats on a great quarter here.
We have no other questions in queue. I'd like to turn the call back over to the speaker for closing remarks.
Thank you all very much, for joining us this morning, and look forward to speaking with you again during our third-quarter earnings call. Thanks again. Bye now.
[Operator signoff]
More CNK analysis


text:
Milivoje Čolak-Antić (5 April 1884–15 April 1944) was a Royal Serbian Army officer, most notable for his command of Chetniks volunteer detachments in Macedonia during the Balkan Wars, and his actions with Operation Departments during World War I for which he received multiple awards.

Biography
Milivoje P. Čolak-Antić was born on 5 April 1884 in Kragujevac, his paternal grandfather was Vojvoda Čolak-Anta Simeonović a renowned rebel leader under Karađorđe during the First Serbian Uprising, while his mother Jelena was the sister of painter Milan Milovanović; he had a sister Milica and a brother Antonije. After graduating from the Imperial Lyceum in Constantinople, he entered the Military Academy in September 1902.

Čolak-Antić graduatued from the military academy in 1906 as infantry second lieutenant. In 1907 he transferred to the Cavalry, volunteered to serve as platoon leader of Komita in southern Serbia during the Macedonian Struggle before becoming platoon officer in the 4th Cavalry Regiment from 1907 to 1911. The following year he was sent to France to train with the 7e Regiment de Dragons.

At the start of the First Balkan War, two Chetnik detachments were established in Macedonia with one of them, the Transvardar detachment placed under his command. His unit was sent in the area of Poreče, Kičevo and Debar representing 16 companies. The task of Čolak Antić and his Chetnik companies was to act as the vanguard of the Royal Serbian Army in Macedonia facing the Ottoman forces. Čolak-Antić later served as platoon officer in the 4th cavalry regiment, platoon officer based in Smederevska Palanka and commander of the 2nd Squadron of the 4th Cavalry Regiment until the end of the war. Towards the end of 1913 he returned to France to study at the École supérieure de guerre in Paris.

Following the invasion of Serbia, and the start of the First World War, Čolak-Antić served with the Operations Department of the Third Army Headquarters until March 1915, before being sent to the Military Delegation in Romania as intelligence officer. For the next two years Čolak-Antić served in the Operations Department of the Headquarters of the Third Army and as adjutant to the Minister of Defence in Shkoder, Corfu and Thessaloniki. In 1917 he then joined the Operations Department of the Supreme Command then the Operations Department of the Headquarters of the First Army. During the Salonika Trial he took part as witness alongside his cousin Colonel Boško Čolak-Antić. In 1917 he became a liaison officer in the Headquarters of the Allied Army of the Orient and was assigned to the Operations Department of the Headquarters of the Cavalry Division a position he held until March 1918.

Following the liberation of the country, after serving with the Operational Department of the Second Army's staff, he returned to the Higher Military School in Paris as a cadet. On his return he was appointed commander of the IV Squadron of the VI Cavalry Regiment, in 1922 joined the general staff, becoming in 1923 lieutenant colonel and assistant commander of the VI Cavalry Regiment, before serving as acting chief of staff of the First Cavalry Division. In 1927, after serving as acting commander of the VIII Cavalry Regiment, he was promoted to Colonel and appointed military attaché in Poland. Towards the end of 1927 he served as head of staff of Navy command in Montenegro followed by commander of the VI Cavalry Regiment, and in 1935 commander of the Dubrovnik garrison in Croatia. At his request, he retired and transferred to the reserve in 1935.

Personal life
Čolak-Antić married Jovana, daughter of Jovan and Klara Gaci from Corfu, the Gaci ran the Bella Venezia hotel which hosted the Serbian government during the occupation of the country. Čolak-Antić and his wife had a son Pavle and a daughter Maja Maria. His sister Milica Krstić became one of the most important female architects in Serbia and Yugoslavia. Čolak-Antić died during the bombing of Belgrade on 15 April 1944, days before the liberation of Yugoslavia.

Military ranks
As a commissioned officer Čolak-Antić held the following ranks:

 Second lieutenant, 1906
 Lieutenant, 1910
 Captain II class, 1913
 Cavalry captain I class, 1915
 Cavalry major, 1918
 Cavalry lieutenant colonel, 1923
 Cavalry colonel, 1927

Honours
For his action during war as well as in peace time Čolak-Antić was awarded several awards:

Serbia/Yugoslavia
 Order of Karađorđe's Star
 Medal for Bravery, Gold
 Order of the White Eagle
 Order of St. Sava
 Order of the Yugoslav Crown (2)

Romania
 Order Of The Crown

Czechoslovakia
 Order of the White Lion

See also
 Čolak-Antić family

Notes

References

Čolak-Antić family
1884 births
1944 deaths
Military personnel from Kragujevac
People from the Kingdom of Serbia
Royal Serbian Army soldiers
Royal Yugoslav Army personnel
Serbian civilians killed in World War II
Deaths by airstrike during World War II


text:
HTC One M7, M8 owners, you'll have to wait longer for Android 5.0
HTC says several issues with the latest version of Android, dubbed Lollipop, will cause the company to miss its goal of an update within 90 days, the deadline for which falls on Sunday.
Roger Cheng
Jan. 31, 2015 6:21 a.m. PT
Roger Cheng Executive Editor / Head of News
Roger Cheng (he/him/his) is the executive editor in charge of CNET News, managing everything from daily breaking news to in-depth investigative packages. Prior to this, he was on the telecommunications beat and wrote for Dow Jones Newswires and The Wall Street Journal for nearly a decade and got his start writing and laying out pages at a local paper in Southern California. He's a devoted Trojan alum and thinks sleep is the perfect -- if unattainable -- hobby for a parent.
Expertise Mobile, 5G, Big Tech, Social Media Credentials SABEW Best in Business 2011 Award for Breaking News Coverage, Eddie Award in 2020 for 5G coverage, runner-up National Arts & Entertainment Journalism Award for culture analysis.
No update yet for the HTC One M8. CNET
HTC One owners waiting for an update to the latest version of Android will have to practice a bit more patience.
The company said late Friday that it would miss its goal of bringing Android 5.0, also known as Lollipop, to the carrier versions of the HTC One M8 and M7 within 90 days. The deadline for that window would fall on February 1.
Motorola: Why you don't have Android Lollipop yet
HTC sees first year-over-year revenue gain since 2011
CNET's review of the HTC One M8
CNET's take on the Android 5.0 Lollipop
The Taiwanese smartphone maker's mission to keep its products up to date with the latest software is one of the ways it hopes to stand apart and build customer loyalty for its products. Consumers have grown increasingly savvy about the version of Android on their devices, with many clamoring for faster updates. HTC needs the edge: Once a major player in the smartphone business known for its design acumen, it's since been trampled by heftier competitors such as Samsung, or companies such as Xiaomi that focus on low-cost devices.
But HTC has shown signs of life. Earlier this month, it reported its first fourth-quarter gain in revenue, year over year, since 2011. The gain was helped by the Nexus 9 and a widening line of midrange smartphones.
On the update, HTC was delayed by issues that needed to be addressed with Lollipop, Mo Versi, vice president of product management, said in a blog post Friday. The issues need to be vetted by both HTC and its carrier partners.
"We are continuing to push hard to deliver Lollipop to all devices as near the 90-day mark as possible, but we are taking every precaution to ensure the rollout is right and we aren't willing to compromise at your expense," Versi said.
HTC has already pushed the update to the Google Play, Developer and unlocked editions of the HTC One M8, which don't have carrier partners.
HTC isn't the only one to deal with update issues. In a blog post Thursday, Motorola laid out some of the challenges involved with the Lollipop update. It had finally brought Android 5.0 to Moto G in India and Brazil, despite updating the phone in other regions as far back as November (second-generation Moto G users in the US will get it in phases). The challenges go back to the need to perform additional tests before an update can be pushed to a large number of users.
Like HTC, Motorola has set a commitment to update its smartphones to the latest version of Android.


We aim in this workshop to establish the use of in situ simulation as a tool to enhance team working in high-risk clinical scenarios in the workplace. In addition, we aim to outline its use in discovering areas where local systems need improvement and in revealing latent threats to patients. We will spend some time discussing scenario design and equipment used to run a scenario, including mannequins, actors, communication aids. We will discuss the importance of the effective debrief in maximising the educational value of a simulated session. The workshop will take the format of group discussions, with demonstration of a pre-hospital scenario, and group feedback. Delegates will be able to share their own experiences, and additional skills may be gained and distributed to their own places of work.
This PDF has been produced for your convenience. Always refer to the live site https://www.rrh.org.au/journal/article/4081 for the Version of Record.


text:
Taking a Tour of the New Florida Polytechnic University
WUSF Public Media - WUSF 89.7 | By Steve Newborn
Steve Newborn / WUSF News
Entrance to the Innovation, Science and Technology Building
Workers put the finishing touches in before Saturday's grand opening
Credit Steve Newborn / WUSF News
The work of architect Santiago Calatrava
Florida's 12th university opens to the public Saturday with the grand opening of Florida Polytechnic U. More than 550 students are expected for the first day of class on August 25th. The Lakeland campus is the state's first public university devoted to STEM - science, technology and mathematics.
In-state undergraduate students who enroll at the university will get free tuition. Florida Poly freshmen will receive full in-state tuition for three years, and then more than half tuition for the fourth year of enrollment. Grad students will get about 80 percent of their tuition and fees paid. The University's Foundation board will have primary responsibility in raising the more than $8 million needed for the scholarships.
The University's leaders say that free tuition will help draw competitive students to a brand new school whose accreditation is still in the works.
On Saturday, state and university leaders will gather for a special LAUNCH Ceremony to celebrate the completion of the iconic Innovation, Science and Technology (IST) Building and the official opening of Florida Polytechnic.
The ceremony will take place outdoors on the south side of the IST Building. Guests scheduled to speak include President Dr. Randy K. Avent, Chief Operating Officer Ava L. Parker and Florida Polytechnic University Board of Trustees Chair Robert H. Gidel. IST Building architect Dr. Santiago Calatrava. State government and education leaders including Commissioner of Agriculture Adam Putnam, Representative Seth McKeel, Governor Wendy Link of the State University System Board of Governors and former Florida Senator J.D. Alexander.
For details, visit http://floridapolytechnic.org/LAUNCH.
WUSF's Steve Newborn takes us on a tour of their signature new building along Interstate 4 with school spokeswoman Crystal Lauderdale. She lauds the work of the building's architect, Spaniard Santiago Calatrava.
Education Florida Polytechnic UniversityFlorida PolytechnicUniversity Beateducation
Steve Newborn
Steve Newborn is a WUSF reporter and producer at WUSF covering environmental issues and politics in the Tampa Bay area.
See stories by Steve Newborn
Teachers are sharing their biggest challenges, in their own words.
Q&A with Florida Polytechnic University President Randy Avent
Florida Polytechnic University Opens Its First Building
Florida Poly's First Students Get Scholarships


Both Temodar® (temozolomide) and hypofractionated radiotherapy should be considered as standard treatment options in elderly patients with glioblastoma, according to the results of a study published in the Lancet Oncology.
Glioblastoma multiforme (GBM) is one of the most common and fatal types of primary brain cancer. It develops from the glial cells, which are the most abundant cells in the nervous system. Glial cells provide supportive functions that facilitate the work of neurons (cells that transmit impulses between the brain, spinal column, and nerves).
Treatment for GBM often involves surgery followed by radiation and chemotherapy with Temodar. Even with aggressive initial treatment, many patients will survive less than one year after diagnosis.
The incidence of GBM increases with older age, with a median age of 64 at diagnosis. Age has been the most important prognostic factor in GBM—after age 50, median survival decreases with each increasing decade. Age can be a determining factor in treatment, yet data regarding age and treatment modalities is limited.
The Nordic Clinical Brain Tumor Study Group was a randomized clinical trial designed to assess the optimum palliative treatment in patients aged 60 years and older with GBM. The study included 324 patients who were randomized to receive one of three treatments: Temodar, short-course hypofractionated radiotherapy, or 6-week standard radiotherapy.
Overall, the results indicated that median overall survival was significantly longer with Temodar (8.3 months) than with standard radiotherapy, but not with hypofractionated radiotherapy (7.5 months). Overall survival was similar among patients who received Temodar or hypofractionated radiotherapy (8.4 months). In patients over age 70, survival was better with Temodar and hypofractionated radiotherapy than with standard radiotherapy. The analysis further revealed that patients treated with Temodar who had MGMT promoter methylation (an active DNA repair gene) had significantly longer survival (9.7 months) than those without it (6.8 months). The most common grade 3-4 adverse events in the Temodar group were neutropenia and thrombocytopenia.
The researchers concluded that Temodar and hypofractionated radiotherapy should be considered as standard treatment options in elderly patients with GBM; however, standard radiotherapy was associated with poor outcomes, especially in patients over age 70.


text:
Q: Nodejs How to export Socket IO in controller In Nodejs how to export socket IO in controller.
Socket.io Version - "socket.io": "^4.5.1",
Socket.js
let io = null;

// module.exports = {
//     intialized_connection: (httpServer) => {
//         return (io = require('socket.io')(httpServer, {
//             cors: {
//               origin: '*',
//               methods: ['GET', 'POST', 'PUT', 'DELETE'],
//             },
//         }));
//     },

//     getIO: () => {
//         if (!io) {
//             throw new Error('Socket.io is not initialized');
//         }
//         return io;
//     }
// }

class RealTime {
    constructor() {
        if (io) return io;
        io = this;
        return io;
    }

    intialized_connection(httpServer) {
        return (io = require('socket.io')(httpServer, {
            cors: {
              origin: '*',
              methods: ['GET', 'POST', 'PUT', 'DELETE'],
            },
        }));
    }

    init() {
        io.on("connection", function (socket) {
            console.log("A user connected", socket.id);
            //Whenever someone disconnects this piece of code executed

            // socket.on('custom-event', function(data) {
            //     console.log("Atique data: ", JSON.stringify(data));
            // });

            // socket.emit('custom-emit', "hello from nodejs")

            socket.on('disconnect', function () {
                console.log('A user disconnected');
            });
        });
    }

    getIO() {
        if (!io) {
            throw new Error('Socket.io is not initialized');
        }
        return io;
    }

    sendEvents(event, data) {
        console.log("This.Socket:", this.socket);
        return new Promise((resolve, reject) => {
            this.getIO().emit(event, data, (response) => {
                if (response.error) {
                    console.error(response.error);
                    reject(response.error);
                } else {
                    resolve(true);
                }
            });
        });
    }

    receivedEvents(event) {
        console.log("Atique Ahmed Received Events ---->", event);
        return new Promise((resolve, reject) => {
            this.getIO().on(event, function(err, data) {
                console.log("I am emiiting here, ")
                if(err) {
                    reject(err);
                }
                resolve(data);
            });
        })

    }
}

module.exports = {
    RealTime
};

index.js
const express = require('express');
const bodyparser = require('body-parser');
const cors = require('cors');
const fileUpload = require('express-fileupload');
const http = require('http');

// const socketIO = require('./utils/socket');
const { RealTime } = require('./utils/socket');
const socket = new RealTime();

const app = express();

app.use(cors())
app.options('*', cors());

app.use(bodyparser.json({limit: '5mb', extended: true}))
app.use(bodyparser.urlencoded({limit: '5mb', extended: true}))

const authRoutes = require('./routes/authRoutes');
const apiRoutes = require('./routes/routes');

// For File Upload
app.use(fileUpload({
  limits: { fileSize: 5 * 1024 * 1024 },
}));

app.use('/auth', authRoutes);
app.use('/user', apiRoutes);

//Capture All 404 errors
app.use(function (req,res,next){
    res.status(404).send('Error - Unable to find the requested resource!');
});

app.use((req, res, next) => {
  req.socket.on('error', () => {});
  next();
});

const server = http.createServer(app);

socket.intialized_connection(server);
socket.init();

app.set('socketio', socket);//here you export my socket.io to a global

module.exports = server;

local.js
require('dotenv').config()
const server = require('./index');
const port = process.env.PORT || 8081;
const chalk = require('chalk');

// Server
server.listen(port, () => {
    console.log(chalk.green('╔═══════════════════════════════════════════════════════════'));
    console.log(chalk.green('║ Background Server Listening at | port: %s', port));
    console.log(chalk.green('╚═══════════════════════════════════════════════════════════'));
});

Routes.js
const express = require('express');
const bodyParser = require('body-parser');
const app = express();

app.use(bodyParser.json());

// Authentication
const authentication = require('../authentication');

// Middleware
const middleware = require('../middleware/headerValidation');

// Permission
const permissions = require('../permission/index')

// Controller
const userController = require('../controllers/userController');
const customerController = require('../controllers/customerController');

app.post('/submit-request', [middleware.bearerTokenPresent, authentication.verifyToken, permissions.fileUploadPermission], (req, res) => {
   customerController.submitRequest(req, res);
});

module.exports = app;

customerController.js
exports.submitRequest = async(req, res) => {

    const io = req.app.get('socketio');

    io.emit('custom-emit', "Hello from nodejs");

    io.on('custom-event', function(data) {
       console.log("Atique:", JSON.stringify(data))
    })

    res.json("done")
}

Issue are -
The main issues are - socketio.on an socketio.emit is not working. It is working when I am putting everything, inside init method, I can't do that, I have to write the generic code, so it can be re-usable. -
init() {
      io.on("connection", function (socket) {
          console.log("A user connected", socket.id);
          socket.on('custom-event', function(data) {
            console.log("Atique data: ", JSON.stringify(data));
          });
          socket.emit('custom-emit', "hello from nodejs")
          socket.on('disconnect', function () {
            console.log('A user disconnected');
          });
      });
}

Frontend Angular 14, I am using, socket.io-client
Any idea, What I am doing wrong?

A: The object stored in your globals
app.set('socketio', socket);//here you export my socket.io to a global

is an instance of RealTime class and not of the require('socket.io').Server class.
please cache the reference to the proper object like so:

app.set('socketio',socket.intialized_connection(server));//here you export my socket.io to a global

socket.init();

change customerController.js:
exports.submitRequest = async (req, res) => {

    const io = req.app.get('socketio');

    ///edited from io.on("connection", function (socket) {
    io.once("connection", function (socket) {
        socket.emit('custom-emit', "Hello from nodejs");

        socket.on('custom-event', function (data) {
            console.log("Atique:", JSON.stringify(data))
        })

        res.json("done")
    });

}

you however have to keep in mind what listeners you are adding to the io object's "connection" or some other event as No checks are made to see if the listener has already been added. Multiple calls passing the same combination of "connection" and listener will result in the listener being added, and called, multiple times.
Consider using named functions and clearing the listener using removeListener() from time to time.
It is best to keep all your socket event listeners in one file for ease of debugging.
EDIT 1
index.js:

const server = http.createServer(app);

socket.intialized_connection(server);
socket.init();

app.set('socketio', socket);//here you export my socket.io to a global

make the following changes to your socket.js:
let io = null;
/// CHANGE:
let socketID = null;

class RealTime {
    constructor() {
        if (io) return io;
        io = this;
        return io;
    }

    intialized_connection(httpServer) {
        return (io = require('socket.io')(httpServer, {
            cors: {
                origin: '*',
                methods: ['GET', 'POST', 'PUT', 'DELETE'],
            },
        }));
    }

    init() {
        io.on("connection", function (socket) {
            console.log("A user connected", socket.id);
            /// CHANGE:
            socketID = socket.id
            //Whenever someone disconnects this piece of code executed

            // socket.on('custom-event', function(data) {
            //     console.log("Atique data: ", JSON.stringify(data));
            // });

            // socket.emit('custom-emit', "hello from nodejs")

            socket.on('disconnect', function () {
                console.log('A user disconnected');
            });
        });
    }

    /// CHANGE: getIO() {
    getSocket() {
        if (!io) {
            throw new Error('Socket.io is not initialized');
        }
        return io.sockets.sockets.get(socketID);
    }
.
.
.
.

for the receivedEvents and sendEvents to get reference to the socket.
Since you are caching the socket id here, this code will work only for one client properly.
change customerController.js:
exports.submitRequest = async (req, res) => {

    const socket = req.app.get('socketio').getSocket();

        socket.emit('custom-emit', "Hello from nodejs");

        socket.on('custom-event', function (data) {
            console.log("Atique:", JSON.stringify(data))
        })

        res.json("done")

}


The great thing about this recipe is you can use whatever is on hand, or your favourite flavors. Mix and match your choice of meat and vegetables to make the perfect curry for you.
Try serving the curry over steamed rice, fresh rolls, or with naan bread. It is even fantastic served over leftover baked or sautéed potatoes.
Combine everything into a greased 2-quart Dutch oven and mix well.
Cook over medium-high heat, about 180 degrees C (350 degrees F), for 1 hour.


Below you will find a list of your local driving schools and driving instructors offering driving lessons, intensive driving courses and pass plus training in the Harrow HA postcode area.
If you live in one of the following postcode areas WD23, WD2, WD3, WD4, WD5, WD6, WD7, HA6, AL1 and would like more information about driving lessons or intensive driving courses in Watford please don't hesitate to contact me.
If you live in one of the following postcode areas EN1, EN2, EN3, EN4, EN5, EN6, EN7, EN8, EN9, EN10, WD6, HA4, HA5 and would like more information about driving lessons or intensive driving courses in Enfield please don't hesitate to contact me.


text:
RESERVATIONS: +30 210 8981884 Facebook Twitter Pinterest Instagram ABOUT US | CONTACT US |
Zagorohoria
Mountainous Arcadia
Gerolimenas in Mani
Trikala of Korinth
Karpenissi
The Cyclades
THE T CLUB
A city that never sleeps, a modern European metropolis irresistibly charming to every visitor...
Destinations › Central Greece
Did you know that:
The municipality of Vouliagmeni was created in 1935 and includes the areas Small and Large Kavouri, Saint Nikolas and Laimos.
In order to access the area of Glyfada up until 1928, you could either take the main Faliro road by the seaside or by horse carriage via the Athens - Vari road.
Access between Athens and Voulagmeni was established around the year 1920 where a four-horse carriage called the "arabas" could be used.
In 1955, Glyfada's Town Hall moved to a building which was built in 1925 and was previously a night club called Trouvil.
The hospital Asklipio Voulas was established in 1920 and its initial aim was to cure patients of tuberculosis.
In the area of Αnavissos there have been recorded traces of human presence from prehistoric times.
In the area of Glyfada, where today the night club Asteria is located, there used to be the first mixed baths for both men and women. They actually used to be a favourite meeting point for the "good society" of Greece.
Glyfada was envisaged to be a residential area near the sea which would attract Athenians for a swim. This is exactly what its founder Piros Karapanos had in mind when it all started in 1920.
The area of Glyfada at large is one of the richest areas of Athens today. The area's rapid development is connected to the establishment of US bases in the sub-area of Elliniko.
The largest tunnel in the world is 800 m. in length and is found in Lake Vouliagmeni. There are thirteen more tunnels in the area.
The Editor Athens Hotel: Brand new city hotel in central Athens
"A modern-day edition of comfort close to Athens wonders" Created with a deep respect for its heritage, The Editor Athens Hotel...
11 Great Reasons for a Stay at the stunning Margi Hotel
By the famous German travel and lifestyle blogger Karl-Heinz Limberg.
Carnival and Clean Monday celebrations at the Stavros Niarchos Park in Athens
The Stavros Niarchos Cultural Center celebrates the Carnival with a festive program that culminates on Sunday of the Carnival,...
The Christmas World of SNFCC comes to life
Turning into a very special Christmas destination for this year's holiday season, the Stavros Niarchos Foundation Cultural Center...
Christmas in Athens is magical at The Margi Hotel
The Margi Hotel, the best boutique hotel in the riviera of Athens, invites you to live the magic of Christmas, within a warm and...
Book online or call us at:
Copyright © 2020 Trésor Hotels & Resorts
Adventure & Nature
Winter Weekend Getaways
for hoteliers
Hoteliers Registration
Subscribe now and be the first to receive our greatest offers!
Facebook Twitter Pinterest Linkedin gPlus Instagram
your Hidden Holiday Treasure?
Join now T-Club
dive in a world of exclusivities and free upgrades by earning points with every stay.
Live the Authentic Boutique Experience
with discounts up to 30% from our Loyalty Club.