@@ -445,9 +445,6 @@ func GetRecordKey(id string, network string) (string, error) {
func GetNodeByID(uuid string) (models.Node, error) {
if servercfg.CacheEnabled() {
- if len(getNodesFromCache()) == 0 {
- _, _ = GetAllNodes()
- }
if node, ok := getNodeFromCache(uuid); ok {
return node, nil
}
@@ -20,6 +20,7 @@ import (
// Run - runs all migrations
func Run() {
+ _, _ = logic.GetAllNodes()
updateEnrollmentKeys()
assignSuperAdmin()
createDefaultTagsAndPolicies()