Sort is fixed with using AM generic API