adding getsourcefunction sha256 check

This commit is contained in:
2025-10-31 21:32:35 -03:00
parent cbea1dd8b5
commit ff5e271195
3 changed files with 129 additions and 20 deletions

View File

@@ -1,9 +1,5 @@
package packet
import (
"fmt"
)
func (pkg PacketLua) IsValid() bool {
var a, b int
@@ -15,8 +11,7 @@ func (pkg PacketLua) IsValid() bool {
a += len(*pkg.GlobalSources)
if a <= 0 || b <= 0 {
fmt.Println("invalid")
if a < 1 || len(*pkg.Plataforms) > b {
return false
}
@@ -26,7 +21,5 @@ func (pkg PacketLua) IsValid() bool {
case pkg.Description == "" || pkg.Maintaner == "" || pkg.Name == "" || pkg.Version == "":
return false
}
fmt.Println("valid")
return true
}