Skip to content
This repository has been archived by the owner on Nov 30, 2021. It is now read-only.

Commit

Permalink
number nodes by layer
Browse files Browse the repository at this point in the history
  • Loading branch information
Gabriel Monroy committed Jul 25, 2013
1 parent e421b30 commit d6ee9e9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion api/models.py
Expand Up @@ -477,7 +477,7 @@ def __str__(self):
class NodeManager(models.Manager):

def new(self, formation, layer):
existing_nodes = self.filter(formation=formation).order_by('-created')
existing_nodes = self.filter(formation=formation, layer=layer).order_by('-created')
if existing_nodes:
next_num = existing_nodes[0].num + 1
else:
Expand Down

0 comments on commit d6ee9e9

Please sign in to comment.