| Schedule of Earnings Per Share, Basic and Diluted |
The calculations of basic and diluted net (loss) income per share and basic and diluted weighted-average shares outstanding for the three and six months ended June 29, 2019 and June 30, 2018 were as follows (in thousands, except per share data): | | | | | | | | | | | | | | | | | | Three Months Ended | | Six Months Ended | | June 29, 2019 | | June 30, 2018 | | June 29, 2019 | | June 30, 2018 | Numerator: | | | | | | | | Basic: | | | | | | | | Net (loss) income attributable to common stockholders | $ | (65,506 | ) | | $ | (834 | ) | | $ | (67,252 | ) | | $ | 1,020 |
| Diluted: | | | | | | | | Net (loss) income attributable to common stockholders | $ | (65,506 | ) | | $ | (834 | ) | | $ | (67,252 | ) | | $ | 1,020 |
| Plus: undistributed earnings allocated to participating securities | — |
| | — |
| | — |
| | 1,508 |
| Less: undistributed earnings reallocated to participating securities | — |
| | — |
| | — |
| | (1,496 | ) | Net (loss) income attributable to common stockholders | $ | (65,506 | ) | | $ | (834 | ) | | $ | (67,252 | ) | | $ | 1,032 |
| | | | | | | | | Denominator: | | | | | | | | Weighted-average shares outstanding - basic | 32,537 |
| | 30,591 |
| | 32,373 |
| | 30,792 |
| | | | | | | | | Dilutive impact from: | | | | | | | | Options outstanding | — |
| | — |
| | — |
| | 1,967 |
| Restricted stock units | — |
| | — |
| | — |
| | 727 |
| Weighted-average shares outstanding - dilutive | 32,537 |
| | 30,591 |
| | 32,373 |
| | 33,486 |
| | | | | | | | | Net (loss) income per share attributable to common stockholders (Basic): | $ | (2.01 | ) | | $ | (0.03 | ) | | $ | (2.08 | ) | | $ | 0.03 |
| Net (loss) income per share attributable to common stockholders (Diluted): | $ | (2.01 | ) | | $ | (0.03 | ) | | $ | (2.08 | ) | | $ | 0.03 |
|
|
| Schedule of Antidilutive Securities Excluded from Computation of Earnings Per Share |
The following equity shares were excluded from the calculation of diluted net income per share attributable to common stockholders because their effect would have been anti-dilutive for the periods presented (in thousands). | | | | | | | | | | | | | | Three Months Ended | | Six Months Ended | | June 29, 2019 | | June 30, 2018 | | June 29, 2019 | | June 30, 2018 | Stock options | 3,189 |
| | 4,002 |
| | 3,189 |
| | 846 |
| Restricted stock units | 2,412 |
| | 2,514 |
| | 2,412 |
| | 684 |
| Series A Redeemable Convertible Preferred Stock (as converted to common stock) | 5,183 |
| | 4,915 |
| | 5,183 |
| | 4,915 |
|
|