| 629 | } |
| 630 | |
| 631 | def gen_initial_dir_list(self): |
| 632 | |
| 633 | if not self.directory_list: |
| 634 | return None |
| 635 | # Limiting to a max of 100 dirs. This code should be eventually removed from the project. |
| 636 | # The correct way should be calling the dir/list endpoint and use pagination. |
| 637 | limit = 100 |
| 638 | directory_list = [] |
| 639 | for directory in self.directory_list[0:limit]: |
| 640 | |
| 641 | # TODO better to do in SQL |
| 642 | if directory.archived is True: |
| 643 | continue |
| 644 | |
| 645 | directory_list.append(directory.serialize()) |
| 646 | |
| 647 | return directory_list |
| 648 | |
| 649 | def serialize_star_list_PUBLIC(self): |
| 650 | |