The company, however, continues to struggle with low margins.